結果

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

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 41 ms
55,724 KB
testcase_01 AC 39 ms
55,724 KB
testcase_02 AC 40 ms
55,724 KB
testcase_03 AC 38 ms
55,724 KB
testcase_04 AC 85 ms
76,312 KB
testcase_05 AC 79 ms
76,312 KB
testcase_06 AC 80 ms
76,312 KB
testcase_07 AC 79 ms
76,312 KB
testcase_08 AC 80 ms
76,312 KB
testcase_09 AC 80 ms
76,312 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#############################################################

import sys
sys.setrecursionlimit(10**7)

from heapq import heappop,heappush
from collections import deque,defaultdict,Counter
from bisect import bisect_left, bisect_right
from itertools import product,combinations,permutations
from math import sin,cos
#from math import isqrt #DO NOT USE PyPy

ipt = sys.stdin.readline
iin = lambda :int(ipt())
lmin = lambda :list(map(int,ipt().split()))

#############################################################

for _ in range(iin()):
    M = iin()
    D = lmin()
    t = ""
    for i in range(9):
        t += str(i+1)*D[i]
    
    t = int(t)*10**9
    t += (-t)%M
    print(t)
0