program matrix ;
uses wincrt;
const ad=7;
aw=12;
type
dayindex = 1..ad;
weekindex= 1..aw;
oa = array [weekindex,dayindex] of Integer;
var
y: file of integer;
w: Integer;
o: oa;
r: weekindex;
c: dayindex;
begin
{fill matrix }
assign(y,'y');
reset;
for r := 1 to aw do
for c := 1 to ad do
read(y, o[r,c]);
{write results}
writeln('y:');
for r:=1 to 12 do
begin
w:= 0;
for c := 1 to 7 do
w:=r;
writeln('rij',r,'resultaat',w);
end;
end.
uses wincrt;
const ad=7;
aw=12;
type
dayindex = 1..ad;
weekindex= 1..aw;
oa = array [weekindex,dayindex] of Integer;
var
y: file of integer;
w: Integer;
o: oa;
r: weekindex;
c: dayindex;
begin
{fill matrix }
assign(y,'y');
reset;
for r := 1 to aw do
for c := 1 to ad do
read(y, o[r,c]);
{write results}
writeln('y:');
for r:=1 to 12 do
begin
w:= 0;
for c := 1 to 7 do
w:=r;
writeln('rij',r,'resultaat',w);
end;
end.