結果

問題 No.182 新規性の虜
ユーザー MaxMellonMaxMellon
提出日時 2015-08-13 18:33:19
言語 Ruby
(3.3.0)
結果
AC  
実行時間 231 ms / 5,000 ms
コード長 137 bytes
コンパイル時間 110 ms
コンパイル使用メモリ 11,220 KB
実行使用メモリ 40,112 KB
最終ジャッジ日時 2023-08-27 07:30:33
合計ジャッジ時間 5,091 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 82 ms
15,012 KB
testcase_01 AC 80 ms
15,120 KB
testcase_02 AC 81 ms
15,140 KB
testcase_03 AC 81 ms
15,264 KB
testcase_04 AC 82 ms
15,036 KB
testcase_05 AC 80 ms
15,168 KB
testcase_06 AC 80 ms
15,148 KB
testcase_07 AC 82 ms
15,112 KB
testcase_08 AC 146 ms
27,704 KB
testcase_09 AC 199 ms
36,628 KB
testcase_10 AC 187 ms
34,040 KB
testcase_11 AC 174 ms
30,512 KB
testcase_12 AC 118 ms
21,656 KB
testcase_13 AC 83 ms
15,140 KB
testcase_14 AC 83 ms
15,264 KB
testcase_15 AC 82 ms
15,136 KB
testcase_16 AC 81 ms
15,036 KB
testcase_17 AC 80 ms
15,316 KB
testcase_18 AC 136 ms
22,148 KB
testcase_19 AC 118 ms
20,828 KB
testcase_20 AC 105 ms
19,128 KB
testcase_21 AC 138 ms
22,756 KB
testcase_22 AC 114 ms
19,712 KB
testcase_23 AC 83 ms
15,216 KB
testcase_24 AC 231 ms
40,112 KB
testcase_25 AC 129 ms
21,684 KB
testcase_26 AC 102 ms
17,532 KB
testcase_27 AC 80 ms
15,256 KB
evil01.txt AC 226 ms
40,708 KB
evil02.txt AC 224 ms
40,876 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.rb:1: warning: assigned but unused variable - n
Syntax OK

ソースコード

diff #

n = gets
arr = gets.chomp.split.group_by{|e| e}.values.sort_by{|e| e.length}
ans = 0
arr.each { |k| ans += 1 if k.length == 1 }
puts ans
0