結果
| 問題 | No.2707 Bag of Words Encryption | 
| コンテスト | |
| ユーザー |  | 
| 提出日時 | 2024-04-22 13:09:03 | 
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 51 ms / 2,000 ms | 
| コード長 | 208 bytes | 
| コンパイル時間 | 171 ms | 
| コンパイル使用メモリ | 12,544 KB | 
| 実行使用メモリ | 11,776 KB | 
| 最終ジャッジ日時 | 2024-10-14 12:36:31 | 
| 合計ジャッジ時間 | 2,205 ms | 
| ジャッジサーバーID (参考情報) | judge2 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| 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()
            
            
            
        