結果
問題 |
No.717 ファッションへのこだわり
|
ユーザー |
![]() |
提出日時 | 2022-03-24 21:50:52 |
言語 | D (dmd 2.109.1) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 337 bytes |
コンパイル時間 | 2,142 ms |
コンパイル使用メモリ | 205,820 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-06-22 14:39:31 |
合計ジャッジ時間 | 2,755 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 10 |
ソースコード
import std; void main() { int N, M; readf("%d %d\n", N, M); auto S = readln.chomp; auto T = readln.chomp; auto cnts = new long[](2); foreach (s; S) ++cnts[s-'A']; int res; foreach (t; T) { if (cnts[t-'A'] > 0) { --cnts[t-'A']; ++res; } } res.writeln; }