Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- program 12_6(input,output);
- function pow(a,y: integer): real;
- begin
- if (y=0) then pow:=1
- else if (y<0) then pow:=1/pow(a,y+1)/a
- else pow:=pow(a,y-1)*a;
- end;
- begin
- var x,n: integer;
- var k: real;
- read(x,n);
- k:=pow(x,n);
- write(k);
- end.
Advertisement
Add Comment
Please, Sign In to add comment