#include <bits/stdc++.h>
using namespace std;
long long p(int p) {
  long long a = 1;
  for (int i = 1; i <= p; i++) a *= 2;
  if (p == 0) a = 1;
  return a;
}
int main() {
  long long a, b = 0, c = 0;
  cin >> a;
  for (int i = a; i >= 1; i--) b += p(i);
  cout << b << endl;
}
