結果
| 問題 | No.171 スワップ文字列(Med) |
| コンテスト | |
| ユーザー |
noko2250
|
| 提出日時 | 2015-03-23 18:21:22 |
| 言語 | Python3 (3.15.0 + numpy 2.5.4 + scipy 1.18.1 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 27 ms / 1,000 ms |
| + 47µs | |
| コード長 | 294 bytes |
| 記録 | |
| コンパイル時間 | 67 ms |
| コンパイル使用メモリ | 14,976 KB |
| 実行使用メモリ | 11,008 KB |
| 最終ジャッジ日時 | 2026-10-13 23:45:34 |
| 合計ジャッジ時間 | 1,850 ms |
|
ジャッジサーバーID (参考情報) |
judge4_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 11 |
ソースコード
#!/c/Python34/python
# coding: utf-8
from collections import Counter
from math import factorial
def main():
S = input()
C = Counter(S)
ans = factorial(len(S))
for c in C.values():
ans //= factorial(c)
print((ans-1) % 573)
if __name__ == '__main__':
main()
noko2250