結果
| 問題 | No.2707 Bag of Words Encryption |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-04-22 13:09:03 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
AC
|
| 実行時間 | 143 ms / 2,000 ms |
| コード長 | 208 bytes |
| 記録 | |
| コンパイル時間 | 457 ms |
| コンパイル使用メモリ | 20,724 KB |
| 実行使用メモリ | 15,968 KB |
| 最終ジャッジ日時 | 2026-05-01 22:33:12 |
| 合計ジャッジ時間 | 3,821 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 15 |
ソースコード
from collections import defaultdict
n = int(input())
s = list(input())
a = list("ABCDEFGHIJKLMNOPQRSTUVWXYZ")
d = defaultdict(int)
for si in s:
d[si] += 1
for ai in a:
print(d[ai], end="")
print()