結果

問題 No.207 世界のなんとか
ユーザー t_muranot_murano
提出日時 2015-09-19 16:32:14
言語 Crystal
(1.10.0)
結果
WA  
実行時間 -
コード長 209 bytes
コンパイル時間 18,758 ms
コンパイル使用メモリ 254,152 KB
実行使用メモリ 4,580 KB
最終ジャッジ日時 2023-09-13 08:47:24
合計ジャッジ時間 18,460 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 AC 2 ms
4,460 KB
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 2 ms
4,468 KB
testcase_17 AC 3 ms
4,392 KB
testcase_18 AC 2 ms
4,384 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

a, b = gets.not_nil!.split.map{|x| x.to_i}

a.upto(b) do |num|
  if num % 3 == 0
    puts num
    next
  end

  num.to_s.split("").any? do |c|
    if c == "3"
      true
    else
      false
    end
  end
end
0