Cannot HelloWorld with eclipse oxygen scala IDE

Asked 2 years ago, Updated 2 years ago, 72 views

package Sample01

object HelloScala {
  defmain(args:Array [String]) = {
    println("Hello scala");
  }
}

It's simple like the one above, but when I try to do it, I get the following message:

Error: Main class HelloScala not found or could not be loaded

This is an indescribable silly question, but I appreciate your cooperation.

eclipse scala

2022-09-30 14:01

1 Answers

packageSample01

It seems that you can delete the line, but I didn't know why.


2022-09-30 14:01

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.