Program bai1;
uses crt;
var i,x,a,kq:longint;
Begin
clrscr;
writeln('Chuong trinh tinh X^a');
write('X=');readln(x);
write('a=');readln(a);
kq:=1;
for i:=1 to a do
kq:=kq*x;
writeln(x,'^',a,'=',kq:4);
readln;
end.
bài 2:
Program bai2;
uses crt;
var n,i: integer;
s: real;
begin
clrscr;
write('nhap so n ='); readln(n);
s:=0;
for i:= 1 to n do
s:=s+exp(n*ln(i));
writeln('tong =',s :4:2);
readln;
end.