以下のコードにより、このコンパイル時エラーが発生します。Missing closing brace } assumed here
このオブジェクトは、 'Currying' という名前の Scala ワークシート内で定義されています。コードは正しいと思いますか?
object Currying {
def add(x:Int, y:Int) = x + y
add(1, 2) // 3
} //compile error is here
以下のコードにより、このコンパイル時エラーが発生します。Missing closing brace } assumed here
このオブジェクトは、 'Currying' という名前の Scala ワークシート内で定義されています。コードは正しいと思いますか?
object Currying {
def add(x:Int, y:Int) = x + y
add(1, 2) // 3
} //compile error is here