program ex1b;
const
nnotes = 3;
nfiches = 100;
type
fiche = record
num: integer;
nom: string;
groupe: char;
notes: array[1..nnotes] of real;
end;
pfiche = ^fiche;
session = array[1..nfiches] of pfiche;
var
pf: pfiche;
s: session;
ps: ^session;
i: integer;
begin
writeln('Exercice 1 b http://www.Software-DS.com');
new(pf); {
Allocation }
pf^.num := 1;
pf^.nom := 'Toto';
pf^.groupe := 'A';
pf^.notes[1] := 10.0;
pf^.notes[2] := 12.5;
pf^.notes[3] := 8.25;
writeln('Classement:', pf^.num : 0, ' Nom:', pf^.nom, '
Groupe:', pf^.groupe);
for i := 1 to nnotes do
writeln('Note', i : 0, ':', pf^.notes[i] : 0);
dispose(pf); {
désallocation }
writeln;
writeln('©2001 All Rights Reserved to
www.Software-DS.com');
{ ©2001 All
Rights Reserved to http://www.Software-DS.com
23/10/01 }
end.
|