Ask coding questions

← Back to all posts
Qwerty Asks 1#
[deleted]

Do you know what's wrong with the code? Bet you can't find it! By the way, how do you announce stuff on repl?

Answered by Coder100 (17010) [earned 5 cycles]
View Answer
Comments
hotnewtop
Coder100 (17010)
  1. As you know functions need braces, semicolons are needed after every statement, and classes need to be called what their filename is.
class Main {
  public static void main(String[] args) {
    System.out.println("Hello world!");
  }
}
  1. you can't annouce things? Did you mean pinging someone? @Youloob
InvisibleOne (2686)

Easy, you are missing an opening bracket, also you can't really announce stuff on the replit announcements space, you can however just create a share post.

[deleted]

Ok for the anouncing stuff but there are more mistakes in the code

InvisibleOne (2686)

@Youloob Missing {} as well as a ; after the line, and I don't know Java very well so I probably won't be able to spot any more

[deleted]

One more. Hint: It's a capital problem

Coder100 (17010)

lol did you not see mine @Youloob

[deleted]

Sorry!

Coder100 (17010)

lol np notifications take some time @Youloob

[deleted]

Yup