uses crt;
var i,n,m:longint;
a:array[1..1000]of integer;
begin
write('nhap do dai cua day so:');readln(n);
m:=0;
for i:=1 to n do begin
write('nhap phan tu thu ',i,' cua mang:');readln(a[i]);
m:=m+a[i];
end;
write(' tong cua day so la:',m);
readln
end.
uses crt;
var i,n,s:longint;
begin
clrscr;
write('Nhap n: '); readln(n);
for i:=1 to n do
s:=s+i;
write('Tong la: ',s);
readln
end.
uses crt;
var i,n,m:longint;
a:array[1..1000]of integer;
begin
write('nhap do dai cua day so:');readln(n);
m:=0;
for i:=1 to n do begin
write('nhap phan tu thu ',i,' cua mang:');readln(a[i]);
m:=m+a[i];
end;
write(' tong cua day so la:',m);
readln
end.