#include<iostream>
#include<iomanip>
#include<cstdio>
#include<cmath>
#include<cstring>
#include<algorithm>
using namespace std;
long long f[45]={2};
int main(){
	int n;
	cin>>n;
	for(int i=1;i<=n;i++){
		f[i]=f[i-1]*2+2;
	}
	cout<<f[n];
    return 0;
}
