Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Program ktorý vypočíta x na n
- program xnan;
- {$APPTYPE CONSOLE}
- uses SysUtils;
- var n,c,i:byte;
- s:word;
- begin
- { TODO -oUser -cConsole Main : Insert code here }
- write('Zadajte lubovolne cislo: ');
- readln(c);
- write('Zadajte lubovolnu mocninu: ');
- readln(n);
- s:=1;
- for i:=1 to n do
- begin
- s:=s*c;
- end;
- writeln('Umocnenie cisla ',c,' na ',n,' sa rovna: ',s);
- readln;
- end.
Advertisement
Add Comment
Please, Sign In to add comment