結果

問題 No.593 4進FizzBuzz
ユーザー syunsukesyunsuke
提出日時 2019-09-08 13:28:43
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 1,951 ms / 2,000 ms
コード長 315 bytes
コンパイル時間 97 ms
コンパイル使用メモリ 10,652 KB
実行使用メモリ 27,548 KB
最終ジャッジ日時 2023-09-09 22:25:37
合計ジャッジ時間 39,015 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,868 KB
testcase_01 AC 15 ms
7,940 KB
testcase_02 AC 15 ms
7,984 KB
testcase_03 AC 15 ms
7,804 KB
testcase_04 AC 15 ms
7,784 KB
testcase_05 AC 15 ms
7,716 KB
testcase_06 AC 17 ms
7,784 KB
testcase_07 AC 15 ms
7,816 KB
testcase_08 AC 14 ms
7,800 KB
testcase_09 AC 15 ms
7,788 KB
testcase_10 AC 15 ms
7,792 KB
testcase_11 AC 14 ms
7,820 KB
testcase_12 AC 14 ms
7,864 KB
testcase_13 AC 14 ms
7,792 KB
testcase_14 AC 14 ms
7,856 KB
testcase_15 AC 14 ms
7,852 KB
testcase_16 AC 1,896 ms
25,764 KB
testcase_17 AC 1,910 ms
25,576 KB
testcase_18 AC 1,928 ms
25,568 KB
testcase_19 AC 1,874 ms
27,520 KB
testcase_20 AC 1,897 ms
25,440 KB
testcase_21 AC 1,939 ms
25,440 KB
testcase_22 AC 1,948 ms
27,548 KB
testcase_23 AC 1,951 ms
25,748 KB
testcase_24 AC 1,884 ms
25,816 KB
testcase_25 AC 1,909 ms
25,684 KB
testcase_26 AC 1,919 ms
27,452 KB
testcase_27 AC 1,858 ms
27,476 KB
testcase_28 AC 1,868 ms
25,448 KB
testcase_29 AC 1,880 ms
27,548 KB
testcase_30 AC 1,898 ms
25,484 KB
testcase_31 AC 1,877 ms
25,500 KB
testcase_32 AC 1,816 ms
25,636 KB
testcase_33 AC 1,926 ms
27,524 KB
testcase_34 AC 1,860 ms
25,432 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N=input()

L=list(str(N))

T=0
for i in range(len(L)):
    T+=int(L[i])
    
F=0
for i in range(len(L)):
    if i%2==0:
        F-=int(L[len(L)-1-i])
    else:
        F+=int(L[len(L)-1-i])

if T%3==0 and F%5==0:
    print("FizzBuzz")
elif T%3==0:
    print("Fizz")
elif F%5==0:
    print("Buzz")
else:
    print(N)
0