Basic Pascal Tutorial/Chapter 2/Programming Assignment/zh CN

From Free Pascal wiki
Revision as of 03:59, 3 February 2022 by Kai Burghardt (talk | contribs) (Kai Burghardt moved page Programming Assignment 2/zh CN to Basic Pascal Tutorial/Chapter 2/Programming Assignment/zh CN: tidy up main name space: create subpage hierarchy for basic Pascal tutorial...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

български (bg) Deutsch (de) English (en) français (fr) 日本語 (ja) 中文(中国大陆)‎ (zh_CN)

2F - 编程作业 (原作者: Tao Yue, 状态: 未更改)

仍是5个数,求和、求平均数。但这次是输入5个数,并显示出来。

如果需要参考源问题,你应该输入以空格分隔的数字:45 7 68 2 34。

显示效果应该看起来是这个样子:

Number of integers = 5
Number1:      45
Number2:       7
Number3:      68
Number4:       2
Number5:      34
================
Sum:         156
Average:      31.2

作为一个额外练习,你可以尝试将输出写入到文件中;不过,我不会在参考答案中说明。

上一页 目录 下一页