N = int(input()) string = "" for i in range(1, N + 1): if i % 3 == 0: if i % 5 == 0: string += "FizzBuzz" else: string += "Fizz" elif i % 5 == 0: string += "Buzz" else: string += str(i) print(string.count("z"))