n = int(input()) if n <= 3: print(n) else: print(n * 5 - 12)