p=int(input()) p=pow(2,p)-1 p=str(bin(p))[2:] p=sum(list(map(int,list(p)))) print(p)