History java MCQ Questions and Answers

0
Text Example

History java  MCQ Questions and Answers




1) Java is a Successor to which programming language?

A) B

B) C

C) C++

D) D

Answer [=]

C

Explanation:

C++ introduced OOPs (Object Oriented Programming) concepts which are adopted by Java.

2) Who invented Java language?

A) Dennis Ritchie

B) James Gosling

C) Larry Page

D) Serge Page

Answer [=]

B

Explanation:

James Gosling along with his team members Mike Sheridan and Patrick Naughton developed Java language.

3) What is the original name of Java Programming language?

A) J++

B) C++

C) OAK

D) TEAK

Answer [=]

C

Explanation:

Java was named after an OAK tree outside James Gosling's office.

4) Which laboratory was Java invented or developed in?

A) Bell Laboratory

B) Sun Microsystems

C) Dennis Ritchie Office

D) Johnson and Johnson

Answer [=]

B

Explanation:

NFS (Network File System) was also invented by SUN Microsystems.

5) The name "JAVA" is known to the world as?

A) A Tea Brand in India

B) A Coffee Brand in Africa

C) An Island in Indonesia

D) Ragi Malt Juice

Answer [=]

C

Explanation:

Indonesia is a group of Volcanic Islands with Java sea on one side.

6) Java language was originally developed for operating?

A) TV

B) TV Set-top box

C) Embedded System equipment

D) All the above

Answer [=]

D

7) What type of Java Programs can be run inside a Java supported Web Browser?

A) Stand alone

B) Struts

C) Applets

D) AWT

Answer [=]

C

8) Whic company owns Java at present?

A) IBM

B) Microsoft

C) Sun Microsystems

D) Oracle

Answer [=]

D

Explanation:

Oracle acquired Sun Microsystems in the year 2010.

9) What was the reason for huge initial success of Java?

A) WWW (World Wide Web)

B) Smart TV Evolution

C) Smart Home Automation

D) None of the above

Answer [=]

A

Explanation:

World Wide Web is also known as the INTERNET.

10) What is the advantage of EXE files?

A) Run Faster

B) Efficient

C) No separate program required to run

D) All the above

Answer [=]

D

11) Computer Viruses and Trojans are often transmitted along with which files?

A) JPG files

B) TXT files

C) EXE files

D) .ICO files

Answer [=]

C

12) What is the problem with generation Executable Software (EXE files)?

A) Run only on Windows machines.

B) Linux and Unix expect a different executable format than .EXE

C) Compiler for each machine type like Linux, Unix, Windows and Processor Type needs to be built for generating output files that can run.

D) All the above.

Answer [=]

D

13) What is an Interpreter?

A) An interpreter converts instructions line by line

B) An Interpreter converts source code to low-level code

C) Interpreters are slow to execute

D) All the above

Answer [=]

D

Explanation:

Opposite of Interpreter is a Compiler.

14) What is a Compiler?

A) A Compiler converts all instructions in one go.

B) A compiler converts source code to low-level code

C) Compilers work fast

D) All the above

Answer [=]

D

Explanation:

So a compiler is preferred to an Interpreter.

15) What is the file name extension of a Java source program?

A) .j

B) .ja

C) .java

D) .jax

Answer [=]

C

16) Choose a correct statement about Java source files.

A) Java files are human readable

B) Java files contain Classes with Methods and Variables

C) Import statements import library Classes into our class

D) All the above

Answer [=]

D

17) What is the output of Compilation of Java Program?

A) .class file

B) .cla file

C) .jc file

D) .javax file

Answer [=]

A

18) Byte code is the result of?

A) Compiling a Java file

B) Compiling a Class file

C) Interpreting a Java File

D) Interpreting a Class file

Answer [=]

A

19) What software compiles a Java Program?

A) JRE (Java Runtime Environment)

B) JDK (Java Developer Kit)

C) JVM (Java Virtual Machine)

D) Command Prompt

Answer [=]

B

20) What software runs a Java program on a computer?

A) JRE (Java Runtime Environment)

B) JDK (Java Developer Kit)

C) Command Prompt

D) None of the above

Answer [=]

A

Text Example

1) What does JVM stands for?

A) Java Variable Machine

B) Java Virtual Machine

C) Java Virtual Mechanism

D) None of the above

B

Explanation:

JRE Software creates JVM in the PC. JVM is implemented differently on different machines and hardware so that the Byte Code present in the Class file produces the same output.

2) What is JVM ?

A) JVM is the confined memory area

B) All java programs run inside JVM memory

C) JVM provides security to the computer by giving controlled access to Files and Memory on a computer

D) All the above

D

3) When was first Version of Java i.e Java 1.0 was released?

A) 1991

B) 1994

C) 1996

D) 1999

C

4) What is Portability offered by Java language?

A) Small code size easy to carry occupying less disk space

B) Generating suitable Byte Code for each machine by the Compiler

C) Ability to run the Byte on different machines producing the same behaviour and output

D) Java does not actually provide portability

C

5) What is JIT in Java?

A) Java In Timer

B) Java In Time Thread

C) Just In Time Compiler

D) Just In Time Runnable

C

6) Choose the correct statement about Java?

A) JIT Compiler produces Byte Code from Java file.

B) JIT Compiler takes chunks of Byte Code as input and produces Executable code on that particular machine.

C) JIT Compiler assists the actual JAVAC compiler to compile fast

D) None of the above

B

7) What happens in the absence of JIT Compiler in Java?

A) Byte code is produced slowly

B) Executable Code is produced slowly because of line by line Interpreting

C) Executable Code is produced without portability

D) None of the above

B

8) What are the main Distribution types of Java Software?

A) Java SE (Java Standard Edition)

B) Java EE (Java Enterprise Edition)

C) Java ME (Java Micro Edition)

D) All the above

D

9) What is the Java distribution type used to build Web Apps in Java?

A) Java SE

B) Java EE

C) Java ME

D) Java Embedded

B

Explanation:

Java SE is used to build standalone apps with GUI. AWT and Swings are used mainly.

Java ME is used on Embedded Chips like IOT devices, Vending Machines, Set Top Boxes, ATMs and all.

10) What is LTS mentioned along with Java Version names like Java SE 11 LTS?

A) LTS stands for Long Term Support

B) LTS Versions are patched for security vulnerabilities for up to 5 Years from the release date.

C) Java SE 8 LTS (supported up to March 2022) and Java SE 11 LTS (supported up to September 2023) are available as of now.

D) All the above

D

11) What is Ahead of Time Compiler in Java?

A) Ahead of time compiler compiles java files as and when you type and save.

B) Ahead of time compiler turns byte code to executable code line by line based on requirement

C) Ahead of time compiler is a replacement for JIT compiler to translate all byte code to a single executable file or code to run the program fast and efficient.

D) None of the above

C

12) What is the Java command used to compile a java program from Command Line or Command Prompt or CMD?

A)

>java hello.java

B)

>javac hello.java

C)

>javacomp hello.java

D)

>javacmd hello.java

B

13) What is the command used to Run a Java program form Command Line or Command Prompt or CMD?

A)

javac hello

B)

java hello.class

C)

java hello

D)

java hello.java

C

Explanation:

"java" command expects only a Class Name without the file name extension like .class.

14) What is a Java Editor?

A) Java editor is simply an IDE like Notepad to type or edit java programs. It does not have ability Compiling or Running java programs without installing separate Java Packages on the PC.

B) Java editor is like Eclipse IDE that has shortcut options or buttons to compile and run java programs without using CMD or Command Line.

C) Java IDE searches for the installed Java location for JAVAC, JAVA and JAWAH to compile and run programs for you.

D) All the above

D

Tags

Post a Comment

0 Comments
Post a Comment (0)
Our website uses cookies to enhance your experience. Learn More
Accept !