結果

問題 No.2593 Reorder and Mod 120
ユーザー Nikkuniku029
提出日時 2023-12-29 15:32:02
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 390 bytes
コンパイル時間 280 ms
コンパイル使用メモリ 82,492 KB
実行使用メモリ 77,384 KB
最終ジャッジ日時 2024-09-27 16:09:48
合計ジャッジ時間 2,543 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1
other WA * 10 RE * 16
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
S = input()
from collections import Counter

ans = 0
C_S = Counter(S)
for i in range(min(1000, int(S))):
    isOK = True
    tmp = Counter(S)
    for t in list(str(i).zfill(3)):
        if t in tmp:
            tmp[t] -= 1
        else:
            isOK = False
    for v in tmp.values():
        if v < 0:
            isOK = False
    if isOK:
        ans += 1
print(ans)
0