結果

問題 No.2562 数字探しゲーム(緑以下コンver.)
ユーザー ymskskyymsksky
提出日時 2024-04-10 00:19:28
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 149 ms / 2,000 ms
コード長 332 bytes
コンパイル時間 146 ms
コンパイル使用メモリ 82,244 KB
実行使用メモリ 78,124 KB
最終ジャッジ日時 2024-04-10 00:19:30
合計ジャッジ時間 2,011 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 36 ms
52,332 KB
testcase_01 AC 34 ms
52,060 KB
testcase_02 AC 36 ms
52,884 KB
testcase_03 AC 36 ms
52,136 KB
testcase_04 AC 149 ms
77,828 KB
testcase_05 AC 139 ms
77,784 KB
testcase_06 AC 140 ms
77,848 KB
testcase_07 AC 138 ms
78,124 KB
testcase_08 AC 145 ms
77,780 KB
testcase_09 AC 148 ms
77,824 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

ans = []
t = int(input())
for _ in range(t):
    m = int(input())
    dl = list(map(int, input().split()))
    upper = "".join([str(i + 1) * d for i, d in enumerate(dl)])
    tmp = int(upper + "0" * 9) % m
    lower = str(0 if tmp == 0 else m - tmp).zfill(9)
    res = upper + lower
    ans.append(res)
for an in ans:
    print(an)
0