Lời giải :
program hotrotinhoc;
var n,i: integer;
s : longint;
a: array[1..32000] of integer;
begin
write('N='); readln(n);
for i:=1 to n do
begin
write('a[',i,']='); readln(a[i]);
end;
s:=0;
for i:=1 to n do
s:=s+a[i];
write(s);
readln
end.