0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2024-11-10 02:58:48 +00:00

P5743 【深基7.习8】猴子吃桃

R38781374
This commit is contained in:
Baoshuo Ren 2020-09-23 19:24:13 +08:00 committed by Baoshuo Ren
parent b746c74481
commit 70cc61de43
Signed by: baoshuo
GPG Key ID: 70F90A673FB1AB68

17
problem/P5743/P5743.cpp Normal file
View File

@ -0,0 +1,17 @@
// R38781374
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, sum;
sum = 1;
cin >> n;
for (int i = n-1; i > 0; i--) {
sum++;
sum *= 2;
}
cout << sum;
return 0;
}