Pagini recente » Cod sursa (job #792529) | Cod sursa (job #2370226) | Cod sursa (job #439709) | Cod sursa (job #3292474) | Cod sursa (job #1095772)
#include <iostream>
#include <fstream>
#include <algorithm>
#include <vector>
#include <string>
#include <map>
#include <iomanip>
#include <cmath>
#define e '\n'
using namespace std;
#define FILE "lgput"
#define INF 1023456789
#define ll long long
#ifdef FILE
ifstream f(string (string(FILE) + ".in").c_str());
ofstream g(string (string(FILE) + ".out").c_str());
#endif
#ifndef FILE
#define f cin
#define g cout
#endif
ll i, j, n, m;
#define NMOD 1999999973
int pw(ll x, ll y) {
if (y == 1) return x % NMOD;
if (y == 0) return 1;
ll tmp = pw (x, y/2);
if (y % 2 == 0) {
return tmp * tmp % NMOD;
}
return (tmp * tmp) % NMOD * x % NMOD;
}
int main() {
f >> n >> m;
g << pw(n % NMOD, m) << e;
}