Java MCQs with answers Page - 1

Here, you will find a collection of MCQ questions on Java. Go through these questions to enhance your preparation for upcoming examinations and interviews.

To check the correct answer, simply click the View Answer button provided for each question.

Have your own questions to contribute? Click the button below to share your MCQs with others!

+ Add Question

A

Admin • 799.53K Points
Coach

Q. What is the lastest version of Java?

  • (A) 17
  • (B) 21
  • (C) 9
  • (D) 8

A

Admin • 799.53K Points
Coach

Q. Identify the incorrect statement?

  • (A) Java is programming language
  • (B) Java is a platform
  • (C) Java is dynamically typed
  • (D) Java is statically typed

A

Admin • 799.53K Points
Coach

Q. JVM stands for ____

  • (A) Java vacuum machine
  • (B) Java void machine
  • (C) Java Virtual machine
  • (D) Java Virtual model

A

Admin • 799.53K Points
Coach

Q. Which maven plugin creates the project structure?

  • (A) execution
  • (B) dependency
  • (C) properties
  • (D) archetype

A

Admin • 799.53K Points
Coach

Q. Which of the following is not true for Ant?

  • (A) It doesn’t have formal conventions
  • (B) It is procedural
  • (C) It is a tool box
  • (D) It provides lifecycle management

A

Admin • 799.53K Points
Coach

Q. Which command can be used to check maven version?

  • (A) mvn -version
  • (B) maven -version
  • (C) maven -ver
  • (D) mvn -ver

A

Admin • 799.53K Points
Coach

Q. Which of the below is a source code management tool?

  • (A) Git
  • (B) Hudson
  • (C) Maven
  • (D) Jenkins

A

Admin • 799.53K Points
Coach

Q. Which environment variable is used to specify the path to maven?

  • (A) PATH
  • (B) CLASSPATH
  • (C) JAVA_HOME
  • (D) MAVEN_HOME

A

Admin • 799.53K Points
Coach

Q. Which file is used to specify the packaging cycle?

  • (A) dependency.xml
  • (B) build.xml
  • (C) version.xml
  • (D) pom.xml

A

Admin • 799.53K Points
Coach

Q. Which file is used to define dependency in maven?

  • (A) version.xml
  • (B) build.xml
  • (C) dependency.xml
  • (D) pom.xml