答案家

 找回密码
 立即注册
查看: 1968|回复: 2

C programming a modern approach_课后答案

[复制链接]

1万

主题

1万

帖子

81万

积分

校长

Rank: 9Rank: 9Rank: 9

积分
817752
发表于 2017-3-14 12:24:35 | 显示全部楼层 |阅读模式
Answers to Selected Exercises
2. [was #2] (a) The program contains one directive (#include) and four statements (three calls of printf and one return). (b)  
Parkinson's Law:
Work expands so as to fill the time available for its completion. 3. [was #4]
#include <stdio.h>  
int main(void) {
  int height = 8, length = 12, width = 10, volume;  
  volume = height * length * width;  
  printf("Dimensions: %dx%dx%d\n", length, width, height);   printf("Volume (cubic inches): %d\n", volume);
  printf("Dimensional weight (pounds): %d\n", (volume + 165) / 166);  
  return 0; }
4. [was #6] Here's one possible program: #include <stdio.h>  
int main(void) {
  int i, j, k;   float x, y, z;  
  printf("Value of i: %d\n", i);   printf("Value of j: %d\n", j);   printf("Value of k: %d\n", k);  
  printf("Value of x: %g\n", x);   printf("Value of y: %g\n", y);

完整课后答案请下载附件,回复本帖子即可查看解压密码

游客,如果您要查看本帖隐藏内容请回复


游客,如果您要查看本帖隐藏内容请回复
回帖码请关注我们的公众号获取。

请在电脑访问我们的网站下载答案,手机下载可能会造成答案不正常显示!QQ群1097987313公告有详细步骤。

该答案由网友整理提供,如果答案不符请扫描关注我们的公众号反馈给我们。

0

主题

1

帖子

27

积分

幼儿园

Rank: 1

积分
27
发表于 2018-1-2 20:07:17 | 显示全部楼层
3QQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQ

0

主题

5

帖子

193

积分

小学生

Rank: 2

积分
193
发表于 2020-10-28 09:25:25 | 显示全部楼层
3QQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQ
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

CopyRight(c)2016 www.daanjia.com All Rights Reserved. 本站部份资源由网友发布上传提供,如果侵犯了您的版权,请来信告知,我们将在5个工作日内处理。
快速回复 返回顶部 返回列表