Which declaration of the main method below would allow a class to be started as a standalone program. Select the one correct answer.

public static int main(char args[])
public static void main(String args[])
public static void MAIN(String args[])
public static void main(String args)
public static void main(char args[])

WHAT IS THE answer ?

Recommended Answers

what is your guess? if you don't know the answer to this, you are clearly not ready to take the exam.
take a look at the sticky threads that are meant to help beginning programmers.

Jump to Post

All 2 Replies

what is your guess? if you don't know the answer to this, you are clearly not ready to take the exam.
take a look at the sticky threads that are meant to help beginning programmers.

the correct on which matches with the signature of the one defined was...
2.public static void main(String args[])
otherwise remaining will complile but not execute...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.