Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
Program HelloWorld(output);
var i,num : integer;
begin
i:=0;
writeln('Enter the number of terms u want to be calculated');
readln(num);
If (num/round(num)) <> 1 then
begin
writeln('Please Input an intger');
end;
if (num=1) then
writeln('The answer is 1');
else while (i<=num) do
begin
num := num * 10^(i + 1;
i:=i+1;
end;
writeln('The answer is ',num);
end.
Advertisements
We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.
AcceptLearn more