| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 734 人关注过本帖
标题:关于单位转换的问题
只看楼主 加入收藏
story0723
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2011-12-5
结帖率:0
收藏
已结贴  问题点数:20 回复次数:1 
关于单位转换的问题
初学者,这道题实在不知怎么做,还求各位大师指导!

2. (45 pts) Adapted from Exercise 8.40 in Deitel & Deitel’s C How To Program. Write a program that will assist the user with metric conversions. Your program should allow the user to specify the names of the units as strings (i.e., centimeters, liters, grams, and so on for the metric system and inches, quarts, pounds, and so on for the English system) and should respond to simple questions such as

            "How many inches are in 2 meters?"

            "How many liters are in 10 quarts?"

Your program should recognize invalid conversions. For example, the question

            "How many feet in 5 kilograms?
is not meaningful, because "feet" are units of length while "kilograms" are units of mass. Assume that you may only use the following prefixes for the metric conversions: milli-, centi-, deci-, deka-, hecto-, kilo-. Assume that the English system conversions do NOT have prefixes.

谢谢!!!
搜索更多相关主题的帖子: English system simple assist meters 
2011-12-05 07:22
embed_xuel
Rank: 19Rank: 19Rank: 19Rank: 19Rank: 19Rank: 19
等 级:贵宾
威 望:58
帖 子:3845
专家分:11385
注 册:2011-9-13
收藏
得分:20 
又是作业帖

总有那身价贱的人给作业贴回复完整的代码
2011-12-05 07:27
快速回复:关于单位转换的问题
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.043644 second(s), 9 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved