結果

問題 No.2562 数字探しゲーム(緑以下コンver.)
ユーザー hirayuu_ychirayuu_yc
提出日時 2023-12-02 15:14:37
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 154 ms / 2,000 ms
コード長 262 bytes
コンパイル時間 157 ms
コンパイル使用メモリ 81,700 KB
実行使用メモリ 76,876 KB
最終ジャッジ日時 2023-12-02 15:14:39
合計ジャッジ時間 1,893 ms
ジャッジサーバーID
(参考情報)
judge13 / judge10
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 36 ms
53,460 KB
testcase_01 AC 36 ms
53,460 KB
testcase_02 AC 37 ms
53,460 KB
testcase_03 AC 36 ms
53,460 KB
testcase_04 AC 122 ms
76,156 KB
testcase_05 AC 154 ms
76,876 KB
testcase_06 AC 115 ms
75,908 KB
testcase_07 AC 127 ms
76,028 KB
testcase_08 AC 111 ms
76,044 KB
testcase_09 AC 138 ms
76,876 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

T=int(input())
for i in range(T):
    M=int(input())
    d=list(map(int,input().split()))
    ans=0
    for j in range(9):
        for k in range(d[j]):
            ans*=10
            ans+=j+1
    ans*=10**9
    if ans%M!=0:
        ans+=(-ans)%M
    print(ans)
0