tham khảo
program bt;
uses crt;
var a:array[1..1000] of integer;
i,n,tong,tich:integer;
begin
clrscr;
write('Do dai cua day la:'); readln(n);
for i:=1 to n do
begin
write('a[',i,']='); readln(a[i]);
end;
tong:=0; tich:=1;
for i:=1 to n do
begin
tong:=tong + a[i];
tich:=tich*a[i];
end;
write('tong cac so tu nhien nhap tu ban phim:',tong);
writeln;
write('tich cac so tu nhien nhap tu ban phim:',tich);
readln
end.