Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <math.h>
- using namespace std;
- int a,b;
- int potega(int a, int b)
- {
- if(a==10)
- {
- int w=pow(a,b);
- }
- else
- {
- return pow(a,b);
- }
- }
- int main()
- {
- cout << potega(1,2) << endl;
- cout << potega(3,4) << endl;
- cout << potega(5,6) << endl;
- cout << potega(7,8) << endl;
- return 0;
- }
Add Comment
Please, Sign In to add comment