Q. In order for a source code file, containing the public class test, to successfully compile, which of the following must be true?

  • (A) It must have a package statement
  • (B) It must be named test.java
  • (C) It must import java.lang
  • (D) It must declare a public class named test.
πŸ’¬ Discuss
βœ… Correct Answer: (B) It must be named test.java

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
306
Total Visits
πŸ“½οΈ
4 y ago
Published
πŸŽ–οΈ
Ram Sharma
Publisher
πŸ“ˆ
86%
Success Rate