def fun(n): if n % 2 == 0: return n // 2 return (n + 3) // 4 print(fun(int(input())))