結果

問題 No.965 門松列が嫌い
ユーザー tamarontamaron
提出日時 2020-01-13 20:59:08
言語 Ruby
(3.2.2)
結果
AC  
実行時間 83 ms / 1,000 ms
コード長 130 bytes
コンパイル時間 66 ms
コンパイル使用メモリ 11,376 KB
実行使用メモリ 15,328 KB
最終ジャッジ日時 2023-08-23 13:49:48
合計ジャッジ時間 1,618 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 81 ms
15,076 KB
testcase_01 AC 83 ms
15,036 KB
testcase_02 AC 83 ms
15,312 KB
testcase_03 AC 82 ms
15,232 KB
testcase_04 AC 83 ms
15,240 KB
testcase_05 AC 82 ms
15,128 KB
testcase_06 AC 83 ms
15,304 KB
testcase_07 AC 83 ms
15,328 KB
testcase_08 AC 81 ms
15,084 KB
testcase_09 AC 83 ms
15,232 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

a,b,c=gets.split.map(&:to_i)
a,c=c,a if c<a
if b<a && a<c 
    puts [c-a,a-b].min
elsif a<c && c<b
    puts [c-a,b-c].min
end
    
0