- 1、本文档共11页,可阅读全部内容。
- 2、有哪些信誉好的足球投注网站(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
写出程序实现的功能
以下是Pascal语言程序源代码,请分别写出程序实现的功能。 程序01:Program suma(input,output); var a,b,sum:integer; begin ? write(Please input a,b:); ? read(a,b); ? writeln(a=,a); ? writeln(b=,b); ? sum:=a+b; ? write(sum) end. 程序02:Program jh (input,output); var ???? zhi:real; ???? i,n:integer; begin ? write(Input n:); ? read(n); ? zhi:=1; ? for i:=2 to n do ??? zhi:=zhi*i; ? write(zhi) end. 程序03:program? may(input,output); var? far:real; ???? n,i:integer; begin ? write(Please input n:); ? read(n); ? far:=1; ? for i:=2 to n do ??? far:=far+i; ? writeln(far) end. 程序04:Program? agr(input,output); var? fap,jie:real; ???? s,i,n:integer; begin ? write(Please input s:); ? read(s); ? fap:=1; ? for i:=2 to s do ?? begin ???? jie:=1; ???? for n:=1 to i? do ??????? jie:=jie*n; ???? fap:=fap+jie; ?? end; ??write(fap) end. 程序05:Program zdszxs(input,output); type ? num=array [1..10] of integer; var ? a:num; ? i,x,d:integer; begin ? for i:=1 to 10 do ??? read(a[i]); ? x:=a[1]; ? d:=a[1]; ? for i:=2 to 10 do ?? begin ??? if x=a[i] then x:=a[i]; ??? if da[i] then d:=a[i] ?? end; write(x,d) end. 程序06:Program onceg(input,output); var? a,b,c,i:integer; begin ? for i:=100 to 999 do ? begin ?? a:=i div 100; ?? b:=(i-a*100) div 10; ?? c:=i-a*100-b*10; ?? if a*a*a+b*b*b+c*c*c=i then? writeln(i) ? end end. 程序7:program? cfa(input,output); var a,b:integer; begin a:=1;b:=1; for b:=1 to 9 do ? begin ??? for a:=1 to b do ????? write(a,*,b,=,a*b, ); ??? writeln; ? end end. 程序8:program mmd(input,output); begin var ??? k,n:integer; for k:=1 to 5? do begin ? for n:=1 to? 5 do ?? write(*) end; writeln end. 程序9:program maizi(input,output); var ? m,a:real; ? i,n:integer; begin n:=2;m:=1; for n:=2 to 64 do ? begin ?? a:=1; ?? for i:=1 to n-1 do ???? a:=a*2; ?? m:=m+a ? end; ? writeln(m) end. 程序10:program? spx(input,output); var? a:array [1..10] of integ
您可能关注的文档
- 兆核磁预约system使用的说明.ppt
- 修辞角度鉴赏散文的语言的表达效果.ppt
- 信息素养信息检索的相关概念文献检索方法途径图书馆.ppt
- 信诚保险「至佳搭档」医疗健康保险的计划产品的方案篇.ppt
- 先进员工讲训——细则与礼仪.ppt
- 傻根去旅游信用工具与外汇.ppt
- 兆赫天津一汽车型广告策划项目投标的方案.ppt
- 修身养性赢在职场-别对自己说不可能.ppt
- 全国二卷实验题比较.ppt
- 元素和其化合物考查剖析[共44张].ppt
- 25上半年2期套题班-行政职业能力测验(八).docx
- 公考讲义-2025年1月时政汇总.pdf
- 2025年省考逻辑填空1000 高频实词积累+刷题早读课 讲义.pdf
- 25上半年2期套题班-行政职业能力测验(九).docx
- 2025四川事业编FB综合岗考试-综合能力测试讲义-主观题基础,案例分析题,公文写作及文章写作题.pdf
- 25上半年2期套题班-行政职业能力测验(五).docx
- 2025申论多省联考刷题课真题资料-2025国考执法课程.doc
- 2025申论多省联考刷题课真题资料-2024江西执法课程.doc
- 25上半年2期套题班-行政职业能力测验(十).docx
- 2025申论多省联考刷题课真题资料-2024福建县乡课程.doc
文档评论(0)