Pagini recente » Cod sursa (job #3290589) | Cod sursa (job #1495158) | Cod sursa (job #1175240) | Cod sursa (job #2849985) | Cod sursa (job #3283832)
#include <vector>
#include <fstream>
#include <bitset>
#include <queue>
using namespace std;
ifstream fin("lgput.in");
ofstream fout("lgput.out");
long long n, p;
const int mod = 1999999973;
long long put(int a, int b)
{
long long p = 1;
while (b)
{
if (b % 2 == 1)
p = p * a % mod;
a = a * a % mod;
b /= 2;
}
return p;
}
int main()
{
fin >> n >> p;
long long x = put(n, p);
fout << x;
return 0;
}