标签:false cout end long ace ++ code include return
#include<bits/stdc++.h>
using namespace std;
#define ll long long
const ll mn=1e18;
ll pow(ll a,ll b,ll n){
ll ans=1;
ll base=a;
while(b){
if(b&1) ans=ans*base%n;
base=base*base%n;
b>>=1;
}
return ans;
}
int main(){
ll x,y;
ios::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
while(cin>>x>>y){
cout<<pow(x,y,mn)<<endl;
}
return 0;
}
标签:false cout end long ace ++ code include return
原文地址:https://www.cnblogs.com/mch5201314/p/9523473.html