結果

問題 No.647 明太子
ユーザー cielciel
提出日時 2018-01-30 23:15:30
言語 Ruby
(3.3.0)
結果
AC  
実行時間 843 ms / 4,500 ms
コード長 205 bytes
コンパイル時間 134 ms
コンパイル使用メモリ 11,352 KB
実行使用メモリ 15,820 KB
最終ジャッジ日時 2023-09-09 09:20:26
合計ジャッジ時間 5,978 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 81 ms
15,060 KB
testcase_01 AC 79 ms
15,112 KB
testcase_02 AC 81 ms
15,228 KB
testcase_03 AC 81 ms
15,164 KB
testcase_04 AC 80 ms
15,112 KB
testcase_05 AC 81 ms
15,136 KB
testcase_06 AC 80 ms
15,220 KB
testcase_07 AC 81 ms
15,272 KB
testcase_08 AC 81 ms
15,164 KB
testcase_09 AC 91 ms
15,284 KB
testcase_10 AC 102 ms
15,132 KB
testcase_11 AC 87 ms
15,092 KB
testcase_12 AC 96 ms
15,116 KB
testcase_13 AC 117 ms
15,112 KB
testcase_14 AC 465 ms
15,416 KB
testcase_15 AC 134 ms
15,020 KB
testcase_16 AC 96 ms
15,144 KB
testcase_17 AC 561 ms
15,524 KB
testcase_18 AC 607 ms
15,704 KB
testcase_19 AC 282 ms
15,696 KB
testcase_20 AC 289 ms
15,460 KB
testcase_21 AC 156 ms
15,364 KB
testcase_22 AC 843 ms
15,820 KB
testcase_23 AC 85 ms
15,112 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.rb:10: warning: `*' interpreted as argument prefix
Syntax OK

ソースコード

diff #

a=gets.to_i.times.map{gets.split.map &:to_i}
b=gets.to_i.times.map{
	x,y=gets.split.map &:to_i
	a.count{|x0,y0|x0>=x&&y0<=y}
}
if b.all?{|e|e==0}
	p 0
else
	m=b.max
	p *(1..b.size).select{|i|b[i-1]==m}
end
0