結果
問題 | No.446 ゆきこーだーの雨と雪 (1) |
ユーザー | basie23 |
提出日時 | 2016-12-11 16:25:54 |
言語 | Ruby (3.3.0) |
結果 |
AC
|
実行時間 | 82 ms / 2,000 ms |
コード長 | 523 bytes |
コンパイル時間 | 644 ms |
コンパイル使用メモリ | 11,256 KB |
実行使用メモリ | 15,328 KB |
最終ジャッジ日時 | 2023-08-19 11:22:57 |
合計ジャッジ時間 | 2,402 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge14 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 82 ms
15,044 KB |
testcase_01 | AC | 82 ms
15,068 KB |
testcase_02 | AC | 81 ms
15,312 KB |
testcase_03 | AC | 81 ms
15,168 KB |
testcase_04 | AC | 82 ms
15,148 KB |
testcase_05 | AC | 82 ms
15,268 KB |
testcase_06 | AC | 81 ms
15,324 KB |
testcase_07 | AC | 81 ms
15,220 KB |
testcase_08 | AC | 81 ms
15,268 KB |
testcase_09 | AC | 80 ms
15,112 KB |
testcase_10 | AC | 81 ms
15,328 KB |
testcase_11 | AC | 80 ms
15,012 KB |
testcase_12 | AC | 80 ms
15,128 KB |
testcase_13 | AC | 81 ms
15,076 KB |
testcase_14 | AC | 79 ms
15,040 KB |
testcase_15 | AC | 80 ms
15,300 KB |
testcase_16 | AC | 80 ms
15,320 KB |
コンパイルメッセージ
Syntax OK
ソースコード
a = gets.chomp b = gets.chomp def check_has_str(str) str.each_char do |c| if c !~ /\d+/ puts 'NG' exit end end end def check_zero_digit(str) if str.length < 2 return end str.each_char do |c| if c == '0' puts 'NG' exit else return end end end def check_over_12345(int) if int > 12345 puts 'NG' exit end end check_has_str(a) check_has_str(b) check_zero_digit(a) check_zero_digit(b) check_over_12345(a.to_i) check_over_12345(b.to_i) puts 'OK'