結果

問題 No.83 最大マッチング
ユーザー jamadjamad
提出日時 2017-06-24 20:56:04
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
WA  
実行時間 -
コード長 281 bytes
コンパイル時間 1,117 ms
コンパイル使用メモリ 10,488 KB
実行使用メモリ 8,880 KB
最終ジャッジ日時 2023-07-27 10:06:40
合計ジャッジ時間 4,171 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 206 ms
8,788 KB
testcase_01 AC 205 ms
8,796 KB
testcase_02 AC 205 ms
8,712 KB
testcase_03 AC 205 ms
8,740 KB
testcase_04 AC 203 ms
8,804 KB
testcase_05 AC 210 ms
8,876 KB
testcase_06 AC 204 ms
8,692 KB
testcase_07 AC 205 ms
8,720 KB
testcase_08 AC 203 ms
8,736 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

A=[6,2,5,5,4,5,6,3,7,6]
for i in range(10,10**5+1):
    x=i
    tmp=0
    while 1:
        one=x%10
        tmp+=A[one]
        rest=x//10
        x=rest
        if x==0:break
    A.append(tmp)
#print(A)
N=int(input())
idx=0
for x in range(10**5+1):
    if N>=A[x]:idx=x
print(idx)
0