結果

問題 No.2785 四乗足す四の末尾の0
ユーザー Akijin_007
提出日時 2024-06-19 01:34:43
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 286 ms / 2,000 ms
コード長 287 bytes
コンパイル時間 3,688 ms
コンパイル使用メモリ 81,964 KB
実行使用メモリ 78,848 KB
最終ジャッジ日時 2024-06-19 01:34:50
合計ジャッジ時間 3,843 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 20
権限があれば一括ダウンロードができます

ソースコード

diff #

T = int(input())

n = [0] * T

for i in range(T):
    n[i] = int(input())

for i in range(T):
    N = n[i]

    if N == 1 or N == -1:
        print("Yes")
    else:
        print("No")

    t = N ** 4 + 4

    c = 0
    while t % 10 == 0:
        c += 1
        t //= 10

    print(c)


0