結果

問題 No.706 多眼生物の調査
ユーザー simansiman
提出日時 2020-09-28 17:48:48
言語 Ruby
(3.3.0)
結果
WA  
実行時間 -
コード長 171 bytes
コンパイル時間 398 ms
コンパイル使用メモリ 11,468 KB
実行使用メモリ 16,076 KB
最終ジャッジ日時 2023-09-15 01:49:14
合計ジャッジ時間 2,092 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 79 ms
15,268 KB
testcase_01 AC 81 ms
15,172 KB
testcase_02 AC 81 ms
15,056 KB
testcase_03 AC 81 ms
15,168 KB
testcase_04 AC 79 ms
15,288 KB
testcase_05 AC 83 ms
15,652 KB
testcase_06 WA -
testcase_07 AC 79 ms
15,168 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

N = gets.to_i
S = N.times.map { gets.chomp }
counter = Hash.new(0)

S.each do |s|
  cnt = s.count('^')
  counter[cnt] += 1
end

puts counter.max_by { |v, cnt| cnt }.first
0