rt 。 洛谷上 T 了一个点。 1e9 真的真的卡不过吗(泣
已去掉freopen
#include<bits/stdc++.h>
using namespace std;
unsigned long long check(int,int);
int main(){
int a,b;
scanf("%d%d",&a,&b);
printf("%lld",check(a,b));
return 0;
}
unsigned long long check(int a,int b){
unsigned long long ans=1;
for(int i=1;i<=b;i++){
ans*=a;
if(ans>1e9) return -1;
}
return ans;
}