結果

問題 No.1644 Eight Digits
ユーザー mahiro72
提出日時 2021-10-04 22:07:56
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 265 bytes
コンパイル時間 213 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 17,700 KB
最終ジャッジ日時 2024-07-22 22:43:59
合計ジャッジ時間 4,525 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 8 WA * 12 TLE * 1 -- * 4
権限があれば一括ダウンロードができます

ソースコード

diff #

import math
K = int(input())
if K==1:exit(print(math.factorial(8)))

ans = 0
tmp=K
while tmp<=87654321:
    if '0' in str(tmp) or '9'in str(tmp):pass
    elif len(set(str(tmp)))!=len(str(tmp)):pass
    else:ans+=math.factorial(8-len(str(tmp)))
    tmp+=K
print(ans)
0