Pagini recente » Diferente pentru problema/dlboss intre reviziile 13 si 12 | Cod sursa (job #1518527) | Diferente pentru utilizator/rigons intre reviziile 5 si 4 | Diferente pentru problema/poligon6 intre reviziile 5 si 4 | Cod sursa (job #1569456)
#include<fstream>
using namespace std;
int pow0(int x,int y)
{
int a=1;
while(y)
{
if(y%2==1)
a=a*x;
a=a*a;
y/=2;
}
return a;
}
int main()
{
long x,y;
ifstream fin("lgput.in");
ofstream fout("lgput.out");
fin>>x>>y;
if(pow0(x,y)>1999999973)
fout<<pow0(x,y)%1999999973;
else
fout<<pow0(x,y);
return 0;
}