output_description: Print the sum of all numbers among the first N terms of the FizzBuzz sequence.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      N
attempt: N = int(input())
  sum0 = 0
  
  p1 = N // 2
  p2 = N % 2
  
  if p2 == 1:
      sum0 = (N + 1) * p1 + (p1 + 1)
  
  else:
      sum0 = (N + 1) * p1
  
  Fizz = N // 3
  Buzz = N // 5
  FizzBuzz = N // 15
  
  sum1 = 0
  sum2 = 0
  sum3 = 0
  
  if Fizz != 0:
      for i in range(Fizz):
          sum1 += 3 * (i + 1)
  
  
  if Buzz != 0:
      for j in range(Buzz):
          sum2 += 5 * (j + 1)
  
  
  if FizzBuzz != 0:
      for k in range(FizzBuzz):
          sum3 += 15 * (k + 1)
  
  
  ans = sum0 + sum3 - (sum1 + sum2)
  
  print(ans)
  
problem_description: Statement
  
  Let us define the **FizzBuzz sequence** a_1,a_2,... as follows:
  
    * If both 3 and 5 divides i, a_i=\mbox{FizzBuzz}.
    * If the above does not hold but 3 divides i, a_i=\mbox{Fizz}.
    * If none of the above holds but 5 divides i, a_i=\mbox{Buzz}.
    * If none of the above holds, a_i=i.
  
  Find the sum of all numbers among the first N terms of the FizzBuzz sequence.
samples: [{"input": "15", "output": "60\n    \n\nThe first 15 terms of the FizzBuzz sequence are:\n\n1,2,\\mbox{Fizz},4,\\mbox{Buzz},\\mbox{Fizz},7,8,\\mbox{Fizz},\\mbox{Buzz},11,\\mbox{Fizz},13,14,\\mbox{FizzBuzz}\n\nAmong them, numbers are 1,2,4,7,8,11,13,14, and the sum of them is 60.\n\n* * *"}, {"input": "1000000", "output": "266666333332\n    \n\nWatch out for overflow."}]