結果

問題 No.207 世界のなんとか
ユーザー negistelnegistel
提出日時 2016-04-17 18:53:03
言語 Scala(Beta)
(3.4.0)
結果
CE  
(最新)
AC  
(最初)
実行時間 -
コード長 259 bytes
コンパイル時間 4,569 ms
コンパイル使用メモリ 225,732 KB
最終ジャッジ日時 2024-04-27 02:19:53
合計ジャッジ時間 4,911 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
コンパイルエラー時のメッセージ・ソースコードは、提出者また管理者しか表示できないようにしております。(リジャッジ後のコンパイルエラーは公開されます)
ただし、clay言語の場合は開発者のデバッグのため、公開されます。

コンパイルメッセージ
-- [E006] Not Found Error: Main.scala:3:26 -------------------------------------
3 |        val Array(a, b) = readLine().split(' ').map(_.toInt)
  |                          ^^^^^^^^
  |                          Not found: readLine
  |
  | longer explanation available when compiling with `-explain`
-- Warning: Main.scala:4:19 ----------------------------------------------------
4 |        for(i <- a to b){
  |                   ^^
  |Alphanumeric method to is not declared infix; it should not be used as infix operator.
  |Instead, use method syntax .to(...) or backticked identifier `to`.
  |The latter can be rewritten automatically under -rewrite -source 3.4-migration.
1 warning found
1 error found

ソースコード

diff #

object Main {
    def main(args: Array[String]): Unit = {
        val Array(a, b) = readLine().split(' ').map(_.toInt)
        for(i <- a to b){
            if(i % 3 == 0 || i.toString.contains('3')){
                println(i)
            }
        }
    }
}
0