Jochen Herrmann
2010-08-26 14:34:41 UTC
Hi all,
I'm a newbie in Scala and had in the past not a lot with the C-world to do
so maybe I simply have overseen something,
but the below code compiles in Eclipse 3.5.2 (Scala IDE updated today)
with an error: "Editor does not contain a main type"
and I have no idea whats wrong .
package RationalPack
TIA
Joe Herrmann
I'm a newbie in Scala and had in the past not a lot with the C-world to do
so maybe I simply have overseen something,
but the below code compiles in Eclipse 3.5.2 (Scala IDE updated today)
with an error: "Editor does not contain a main type"
and I have no idea whats wrong .
package RationalPack
object MyMain {
def main(args:Array[String]){
val x=new Rational(49,13)
val y=new Rational(47,128)
println (x + "+" + y +"=" + x.+(y) )
println (x + "*" + y +"=" + x*y )
}
}
Any idea's / hints ?def main(args:Array[String]){
val x=new Rational(49,13)
val y=new Rational(47,128)
println (x + "+" + y +"=" + x.+(y) )
println (x + "*" + y +"=" + x*y )
}
}
TIA
Joe Herrmann