C++ to Pseudo code

Help me please, I don't really get how to write this into pseudo code.
I need to submit this evening

#include <iostream>

using namespace std;
int pangkat (int x, int n) {
int hasil;
if (n == 0)
{
hasil = 1;
}
else
{
hasil = x*pangkat (x, n-1);
}
return hasil;
}

int main() {
int x, n;
cout << "Masukkan bilangan yang akan dipangkatkan : ";
cin >> x;
cout << "Masukkan bilangan pangkatnya : ";
cin >> n;
cout << "Hasil pemangkatan dari " << x << "^" << n << " adalah " << pangkat (x, n);
return 0;
}
The link below was explained to you in the code below:

http://www.cplusplus.com/forum/beginner/190140/

Look at this link:
http://www.cplusplus.com/search.do?q=pseudocode
Last edited on
Topic archived. No new replies allowed.