結果

問題 No.2153 何コーダーが何人?
ユーザー 👑 tatt61880tatt61880
提出日時 2023-02-12 02:39:15
言語 Kuin
(KuinC++ v.2021.9.17)
結果
AC  
実行時間 4 ms / 2,000 ms
コード長 425 bytes
コンパイル時間 3,672 ms
コンパイル使用メモリ 153,744 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-09-22 21:06:37
合計ジャッジ時間 4,839 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,380 KB
testcase_01 AC 3 ms
4,376 KB
testcase_02 AC 3 ms
4,376 KB
testcase_03 AC 4 ms
4,380 KB
testcase_04 AC 4 ms
4,376 KB
testcase_05 AC 4 ms
4,380 KB
testcase_06 AC 4 ms
4,376 KB
testcase_07 AC 4 ms
4,376 KB
testcase_08 AC 3 ms
4,376 KB
testcase_09 AC 3 ms
4,380 KB
testcase_10 AC 4 ms
4,380 KB
testcase_11 AC 4 ms
4,376 KB
testcase_12 AC 3 ms
4,376 KB
testcase_13 AC 4 ms
4,380 KB
testcase_14 AC 3 ms
4,380 KB
testcase_15 AC 3 ms
4,380 KB
testcase_16 AC 4 ms
4,376 KB
testcase_17 AC 4 ms
4,376 KB
testcase_18 AC 4 ms
4,376 KB
testcase_19 AC 2 ms
4,380 KB
testcase_20 AC 2 ms
4,376 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

func main()
	var n: int :: cui@inputInt()
	var map: dict<[]char, int> :: #dict<[]char, int>
	var a: []int :: #[8]int
	for i(0, n - 1)
		var s: []char :: cui@inputStr()
		var c: int :: cui@inputInt()
		var existed: bool
		var prev: int :: map.get(s, &existed)
		if(existed)
			do a[prev] :- 1
		end if
		do a[c] :+ 1
		do map.add(s, c)
	end for
	for i(0, 7)
		var ans: int :: a[i]
		do cui@print("\{ans}\n")
	end for
end func
0