⌨️
[AtCoder]ABC-162|B - FizzBuzz Sum
設問ページ
提出結果
def getInt():
return int(input())
def main():
n = getInt()
c = 0
for i in range(1, n + 1):
if i % 3 == 0 or i % 5 == 0:
continue
c += i
print(c)
if __name__ == "__main__":
main()
Discussion