t = int(input())if t<=10: print(t*6)elif t<=20: print(60+(t-10)*2)elif t<40: print(80+(t-20))else: print(100)