def charge(n): if n<=0: return 0 elif n<=1 and n>=0: return 5 else: return 5 + round((n-1+0.5))*2 print(charge(1.5))
import math def fee(hour): h = math.ceil(hour) return (h-1)*2 + 5