You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
238 B

#include <bits/stdc++.h>
using namespace std;
int x, n;
long long t = 1;
int main() {
ios::sync_with_stdio(false); //读入输出优化的强迫症
cin >> x >> n;
for (int i = 0; i < n; t = t + t * x, i++);
cout << t;
}