eN Pangkat eM
Greatings everyone, welcome to the pre test. The task for today is to count the amount of steps required for an algorithm to complete its job. The algorithm we use today is exponential algorithm (algoritma perpangkatan). here's the requirement for the algoritm
Format input:
Dua buah bilangan N dan M, dimana (N^M). N is the number you want to power (angka yang ingin dipangkatkan) dan M is the power number (angka pangkatnya) M >= 0
Format Output:
the output includes the number of step and the result of the equation
note : please use loop method, don't use the built in power function.
note 2 : outputs are case sensitive.
Sample input 1 : 2 4
Sample output 1:
step 1 step 2 step 3 step 4 16
Sample input 2 : 3 6
Sample output 2:
step 1
step 2 step 3 step 4 step 5 step 6 729