Created
April 17, 2015 20:44
-
-
Save fernandoalv/095348c9dddf24a6de4f to your computer and use it in GitHub Desktop.
Pow
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <cmath> | |
using namespace std; | |
long pot(long x,long y){ | |
int z; | |
z=pow((x),y); | |
return z; | |
} | |
int main(){ | |
long a,b,c; | |
cout<<"Dame el numero base"<<endl; | |
cin>>a; | |
cout<<"Dame la potencia"<<endl; | |
cin>>b; | |
c=pot(a,b); | |
cout<<c<<endl; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment