Difference between revisions of "Basic Pascal Tutorial/Chapter 1/Solution/fr"
From Lazarus wiki
Jump to navigationJump to searchm |
(Refonte) |
||
Line 1: | Line 1: | ||
− | {{ Solution }} | + | {{Solution}} |
− | + | [[Object Pascal Tutorial/fr|Tutoriel de Pascal Objet]] : Bases / '''Solution de l'exercice''' | |
− | Voici une façon de | + | Voici une façon de réussir l'exercice de la page précédente. |
<syntaxhighlight> | <syntaxhighlight> | ||
(* Author: Tao Yue | (* Author: Tao Yue | ||
Line 42: | Line 42: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
− | { | + | {{Tutorial page navigation/fr|Programming Assignment|Input}} |
− | |||
− | |||
− | | | ||
− |
Revision as of 21:50, 25 October 2015
│
български (bg) │
Deutsch (de) │
English (en) │
français (fr) │
日本語 (ja) │
한국어 (ko) │
русский (ru) │
中文(中国大陆) (zh_CN) │
Tutoriel de Pascal Objet : Bases / Solution de l'exercice
Voici une façon de réussir l'exercice de la page précédente.
(* Author: Tao Yue
Date: 19 June 1997
Description:
Trouver la somme et la moyenne de 5 nombres
Version:
1.0 - original version
*)
program SumAverage;
const
NumberOfIntegers = 5;
var
A, B, C, D, E : integer;
Sum : integer;
Average : real;
begin (* Main *)
A := 45;
B := 7;
C := 68;
D := 2;
E := 34;
Sum := A + B + C + D + E;
Average := Sum / NumberOfIntegers;
writeln ('Nombre d''entiers = ', NumberOfIntegers);
writeln ('Nombre1 = ', A);
writeln ('Nombre2 = ', B);
writeln ('Nombre3 = ', C);
writeln ('Nombre4 = ', D);
writeln ('Nombre5 = ', E);
writeln ('Somme = ', Sum);
writeln ('Moyenne = ', Average)
end. (* Main *)
← | Sommaire | → |