Program HOC24;
var i,n: integer;
t: real;
begin
write('Nhap N: '); readln(n);
for i:=1 to n do t:=t+i;
write('Trung binh cong tu 1 den ',n,' la: ',t/n:1:2);
readln
end.
uses crt;
var i,n,t:integer;
begin
clrscr;
write('Nhap n='); readln(n);
t:=0;
for i:=1 to n do
t:=t+i;
writeln(t/n:4:2);
readln;
end.