N = int(input()) if N < 100: v = 0 for i in range(1000): if i % 5 <= 2: v += 1 else: v -= 1 if v == N: print(i + 1) exit() else: ans = (N - 100) * 5 N = 100 v = 0 for i in range(1000): if i % 5 <= 2: v += 1 else: v -= 1 if v == N: print(ans + i + 1) exit()