ac

zhyf  •  7天前


include <bits/stdc++.h>

using namespace std;

int main() {

long long int a, b, c = 1;
scanf("%d %d", &a, &b);
for (int i = 1; i <= b; i++) {
	c *= a;
	if (c > 1000000000) {
		cout << "-1";
		return 0;
	}
}
cout << c;
return 0;

}


评论:

请先登录,才能进行评论