import numpy as np N = int(input()) dp = np.zeros(6 * N + 1, dtype=np.object) dp[0] = 1 for i in range(8): np.cumsum(dp, out=dp) dp[N + 1:] -= dp[:-N - 1] print(dp[-1])