from fractions import Fraction n = int(input()) res = [Fraction(4),Fraction(3)] if n == 0 or n == 1: print(f"{res[n]:.15f}") else: for i in range(2,n+1): res.append((19 * res[i-1] - 12 * res[i-2])/4) print(f"{res[-1]:.15f}")