- 1、本文档共39页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
- 5、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
- 6、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们。
- 7、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
- 8、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
程序改错201271(Modify the program 201271)
程序改错201271(Modify the program 201271)
[procedures].
Function: for the 1 to 20 factorial and.
Answer:
1. T=1 or t=1.0);
2). T=t*j; or t*=j; or t=j*t;
3). S=s+t; or s+=t; or s=t+s;
4). Printf (jiecheng=%f\n, s);
[procedures].
Function: Calculation of positive integer num the number on the product you.
For example: input 252, output should be 20.
Answer:
Long k=1, 1);
2. Num/=10 or num=num/10);
3). Scanf (%ld, n);
4. Printf (\n%ld\n), fun (n));
[procedures].
Function: find two non-zero positive integer GCD, and as a function return value.
For example: if num1 and num2 were 49 and 21 input output, the common denominator is 7.
Answer:
1) a=b;
2) b=t;
3) r=a%b;
4). Return B return; or (b) or return (b);
[procedures].
Function: enter the ten student achievement statistics from the keyboard, the highest score, the lowest score and the average score.
Max represents the highest score, min represents the lowest score, average score of AVG.
Answer:
1). Float a[10], min, Max, avg;
2). Scanf (%f, a[i]); or scanf (%f, a+i);
3) max=min=avg=a[0];
4). If (mina[i]) or if (a[i]min)
[procedures].
Function: enter the number 10, the average value of the output of 10 numbers
Answer:
1). For (i=1; i10; i++) or for (i=1; i=9; i++)
2). Float score[10], aver or float; aver, score[10];
3). Scanf (%f, score[i]); or scanf (%f, score+i);
4) aver=average (score);
[procedures].
Functions: to determine whether x is isomorphic to integer number. If the same number of purchase, the function returns 1; otherwise 0.
The so-called isomorphism refers to the number in square number it right.
For example: input integer 25, 625 is a square number 25, 25 in the right side of the number is 625,
So 25 is the number of isomorphism.
Note: the value of X by the main function from the keyboard input, less than 1000.
Answer:
Int k, 1);
2) k=x*x;
3. (if) (k%10==x) || (k%100==x) || (k%1000==x))
[procedures].
Function: according to the integer parameter m, the value of the formula is calculated as follows:
Y=11/31/51/7
您可能关注的文档
- 泰山药用植物(The medicinal plants in Taishan).doc
- 泰山极顶(Taishan peak).doc
- 洋务运动的文化意义与中体西用说的提出(The Westernization Movement and the cultural significance of western theory).doc
- 法兰克福学派的中国之旅——从一篇被人遗忘的序言说起(The Frankfurt school Chinese Tour - from a forgotten preface).doc
- 洋酒知识大扫盲(Wine knowledge literacy).doc
- 洛阳春节、牡丹文化(The Spring Festival, Luoyang peony culture).doc
- 法律硕士之优势及如何发挥其优势(The advantage of master of laws and how to exert its advantages).doc
- 法律知识20道经典例题和解析(20 classic example of legal knowledge and analysis).doc
- 活动互动游戏(Play interactive games).doc
- 活动概况(Overview of activities).doc
- 2024年民航职业技能鉴定模考模拟试题附参考答案详解(精练).docx
- 2024年民航职业技能鉴定模考模拟试题附参考答案详解(考试直接用).docx
- 2024年民航职业技能鉴定模考模拟试题精选答案详解.docx
- 外墙外保温及饰面验收标准.doc
- 2024年民航职业技能鉴定模考模拟试题带答案详解(巩固).docx
- 2024年民航职业技能鉴定模考模拟试题附参考答案详解【典型题】.docx
- 2024年民航职业技能鉴定模考模拟试题带答案详解.docx
- 安徽省皖江名校联盟2026届英语高三第一学期期末经典模拟试题含解析.doc
- 2024年民航职业技能鉴定模考模拟试题完整答案详解.docx
- 风机设计防鸟优化-洞察及研究.docx
文档评论(0)