Program Pn;
var
x:array[1..20] of integer;
n,i:integer;
procedure max(n:integer);
var
i,max:integer;
begin
max:=0;
for i:=1 to n do
begin
if max<x[i] then max:=x[i];
end;
Writeln('Elementul maxim=',max);
end;
begin
Writeln('Dati marimea tabloului');
readln(n);
for i:=1 to n do
begin
Write('x[',i,']=');readln(x[i]);
end;
max(n);
readln;
end.