結果

問題 No.446 ゆきこーだーの雨と雪 (1)
ユーザー finefine
提出日時 2016-11-18 22:33:28
言語 Ruby
(3.3.0)
結果
AC  
実行時間 84 ms / 2,000 ms
コード長 185 bytes
コンパイル時間 103 ms
コンパイル使用メモリ 11,472 KB
実行使用メモリ 15,288 KB
最終ジャッジ日時 2023-08-17 11:02:58
合計ジャッジ時間 2,472 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 84 ms
15,132 KB
testcase_01 AC 82 ms
15,228 KB
testcase_02 AC 82 ms
15,228 KB
testcase_03 AC 81 ms
15,216 KB
testcase_04 AC 82 ms
15,160 KB
testcase_05 AC 81 ms
15,156 KB
testcase_06 AC 81 ms
15,120 KB
testcase_07 AC 83 ms
15,124 KB
testcase_08 AC 81 ms
15,128 KB
testcase_09 AC 82 ms
15,276 KB
testcase_10 AC 82 ms
15,152 KB
testcase_11 AC 83 ms
15,288 KB
testcase_12 AC 82 ms
15,228 KB
testcase_13 AC 82 ms
15,148 KB
testcase_14 AC 83 ms
15,268 KB
testcase_15 AC 83 ms
15,156 KB
testcase_16 AC 82 ms
15,056 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

a = gets.chomp
b = gets.chomp
if (a =~ /^[1-9][0-9]*$/ || a == ?0 )&& (b =~ /^[1-9][0-9]*$/ || b == ?0) 
    puts a.to_i <= 12345 && b.to_i <= 12345 ? "OK" : "NG"
else
    puts "NG"
end
0