#include<iostream> #include<algorithm> using namespace std; int main() { int n; cin>>n; int x=1; n--; while(n--) { x=(x+1)*2; } cout<<x; return 0; }
Double click to view unformatted code.