結果

問題 No.481 1から10
ユーザー object1234object1234
提出日時 2019-02-10 16:01:24
言語 Ruby
(3.3.0)
結果
WA  
実行時間 -
コード長 157 bytes
コンパイル時間 243 ms
コンパイル使用メモリ 11,328 KB
実行使用メモリ 15,388 KB
最終ジャッジ日時 2023-09-20 16:32:20
合計ジャッジ時間 2,081 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 86 ms
15,292 KB
testcase_01 AC 85 ms
15,328 KB
testcase_02 AC 85 ms
15,244 KB
testcase_03 AC 82 ms
15,292 KB
testcase_04 WA -
testcase_05 AC 82 ms
15,044 KB
testcase_06 AC 84 ms
15,112 KB
testcase_07 AC 84 ms
15,296 KB
testcase_08 AC 84 ms
15,164 KB
testcase_09 WA -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

count = 0
gets.chomp.split(" ").map(&:to_i).each_cons(2) do |a|
    count += 1
    if a[1] - a[0] > 1
        count += 1
        break
    end
end
puts count
0