← Quiz: Java Introduction: all 10 questions
Quiz: Java Introduction · Question 7 of 10
Which method does the JVM look for to start a program?
Which method does the JVM look for to start a program?
- A.public void main()
- B.static int main(String args)
- C.public static void start(String[] args)
- D.public static void main(String[] args)
Answer & explanation
Correct answer: public static void main(String[] args)
The entry point must be public, static, return void and take a String array.
Can you get the rest right without peeking?
Take the timed Quiz: Java Introduction quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →