結果
| 問題 |
No.311 z in FizzBuzzString
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-12-22 16:54:28 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 317 bytes |
| コンパイル時間 | 957 ms |
| コンパイル使用メモリ | 12,416 KB |
| 実行使用メモリ | 21,376 KB |
| 最終ジャッジ日時 | 2024-12-22 16:54:40 |
| 合計ジャッジ時間 | 11,062 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 7 TLE * 4 |
ソースコード
def main():
n = int(input())
nums = range(1, n + 1)
count = 0
for num in nums:
if num % 3 == 0 and num % 5 == 0:
count += 4
elif num % 3 == 0:
count += 2
elif num % 5 == 0:
count += 2
print(count)
if __name__ == "__main__":
main()