Basic Pascal Tutorial/Chapter 2/Programming Assignment/ja
Deutsch · English · Français · Български · 中文(中国) · 日本語
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追加の課題としてファイルに出力を書き込むことに挑戦してもよい。ただし、練習問題の解答ではファイルは利用していない。
| previous | contents | next |
From the Free Pascal wiki, page "Basic Pascal Tutorial/Chapter 2/Programming Assignment/ja", as it stood on 2022-08-20 after a change by Kai Burghardt, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's Licensing page. If you have concerns about this material, message the admin.
Talk about this page
Nobody has opened a bench for this page yet. Sign in to open one.
