p = int(input()) meru = bin(2**p - 1) print(sum(int(m) for m in meru if m != 'b'))