Lời giải :
Câu 1 :
program hotrotinhoc ;
var i,tong : integer ;
begin
tong:=0; i:=0;
while i<=100 do
begin
i:=i+1;
tong:=tong+i;
end;
write('tong 100 so tu nhien dau tien la:',tong);
readln
end.
Câu 2 :
program hotrotinhoc ;
var i,n,tich : integer ;
begin
write('n='); readln(n);
tich:=0; i:=0 ;
while i<=n do
begin
i:=i+1;
tich:=tich*i;
end;
write('tich n so tu nhien dau tien la',tich);
readln
end.