結果

問題 No.884 Eat and Add
ユーザー yuruhiyayuruhiya
提出日時 2020-10-22 22:58:58
言語 Ruby
(3.3.0)
結果
AC  
実行時間 120 ms / 1,000 ms
コード長 68 bytes
コンパイル時間 379 ms
コンパイル使用メモリ 11,460 KB
実行使用メモリ 24,928 KB
最終ジャッジ日時 2023-09-28 14:56:10
合計ジャッジ時間 3,919 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 80 ms
15,012 KB
testcase_01 AC 79 ms
15,268 KB
testcase_02 AC 79 ms
15,228 KB
testcase_03 AC 116 ms
17,916 KB
testcase_04 AC 117 ms
18,184 KB
testcase_05 AC 120 ms
18,316 KB
testcase_06 AC 107 ms
16,652 KB
testcase_07 AC 88 ms
24,928 KB
testcase_08 AC 89 ms
15,508 KB
testcase_09 AC 92 ms
15,332 KB
testcase_10 AC 80 ms
15,268 KB
testcase_11 AC 81 ms
15,076 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

p gets.split(/0{2,}|^0+|0+$/).sum{[2+_1.count(?0),_1.count(?1)].min}
0