Java MCQ History
Table of Contents
Attend job interviews easily with these Java MCQ History .
Java Basics MCQ is a high-level programming language which is based on C and C++ programming languages. Syntax of Core Java has been adopted from C and C++ languages. Go through tutorials on C before proceeding to Java Tutorials if you do not have basic knowledge about C.
Java History
Java Invention History or Evolution
Java was invented by James Gosling along with his colleagues Mike Sheridan and Patrick Naughton. The original name for Java programming language is OAK, a tree outside of the office of James Gosling. Java got its name from an Island Java which is part of Indonesia. SUN MicroSystems is the office where Java was developed and invented. Java evolved as a goto programming language for any job seeker.
java Story
Java 1.0 was released to the public in the year 1996 though its initial developer version was completed in 1995 itself. It took 4 years to get to the Java 1.0 version from scratch.
Java was developed with an intention of operating various electronic equipment like Set Top Boxes, Televisions (TV)& and other embedded systems. But surprisingly Java became famous with the advent of the World Wide Web. World Wide Web is simply known as the Internet.
People started using the Internet on various computer systems with different Hardware and Operating Systems. So there was a necessity to develop software that works platform independent. Also security was a very big concern as EXE files easily catch and transmit Viruses and Trojans. Java language came to rescue overcoming these platform dependence and security concerns.
java Theory
Java is an Object Oriented Language with Packages and Modules to manage very big projects easily. A Java program is converted into a BYTE CODE file called CLASS file with a file name extension of .CLASS. Java source files are named with a file extension of .JAVA.
To offer Platform Independence, a Java Container called JVM (Java Virtual Machine) is implemented for each type of Machine. You can run the Java Class file containing the byte code on any machine. You get the same output and behaviour on all machines.
B
yte code is interpreted on line by line basis or block by block basis to show output. So a Just In Time Compiler (JIT Compiler) was introduced to turn chunks of byte code to EXE. This gives Java Code a high performance.
Java Applet, a special type of java program which has the ability to run inside a browser attracted millions of users and developers to create Applet based websites that can Show Server Data and Collect Inputs from users. The applet is one of the main reasons behind huge initial success of Java language.
Oracle acquired Sun MicroSystems in 2010. So Java is now maintained by Oracle company itself.
Types of Java Software Distributions
Broadly there are 3 types of Java software distributions available.
- Java SE (Java Standard Edition) – GUI application, Networking
- and Java EE (Java Enterprise Edition) – Servlets and JSP for web development
- Java ME (Java Micro Edition) – For less powerful devices like PDAs, Printers and Embedded Systems
Java Product Version Numbers
Any Java Version staring with number 1. (ONE POINT) is called Internal Version number and the other version number is called Product Version Number.
NO | Internal Version | Product Version |
---|---|---|
1. | Java 1.0 | J2SE 1 |
2. | Java 1.2 | J2SE 2 |
3. | Java 1.3 | J2SE 3 |
4. | Java 1.4 | J2SE 4 |
5. | Java 1.5 | J2SE 5 |
6. | Java 1.6 | Java SE 6 |
7. | Java 1.7 | Java SE 7 |
8. | Java 1.8 | Java SE 8 |
9. | Java 1.9 | Java SE 9 |
10. | Java 1.10 | Java SE 10 |
11. | Java 1.11 | Java SE 11 |
12. | Java 1.12 | Java SE 12 |
Java SE Version Release History or Roadmap
Starting form Java 1.6 or Java 6, J2SE (Java 2 Standard Edition) is called as Java SE. At present Java SE 8 and Java SE 11 versions provide Long Term Support for bugs and security patches.
Version | Release Date | Support Until | Extended Support |
6 | Dec-06 | Dec-15 | Dec-18 |
7 | Jul-11 | Jul-19 | Jul-22 |
8** | Mar-14 | Mar-22 | Mar-25 |
9 (non‑LTS) | Sep-17 | Mar-18 | Not Available |
10 (non‑LTS) | Mar-18 | Sep-18 | Not Available |
11 (LTS) | Sep-18 | Sep-23 | Sep-26 |
12 (non‑LTS) | Mar-19 | Sep-19 | Not Available |
13 (non‑LTS) | September 2019*** | Mar-20 | Not Available |
Uses of Java
At present Java language is used in the following areas. There are many beyond mentioning here.
1. Banking Websites or Servers
2. Mission Control Projects
3. Card Swiping Machines
4. Vending Machines
5. Android Operating System
6. Standard PC Applications with a GUI (Graphical User Interface)
7. Distributed Computing
8. Game Development
Getting Ready for Hands on Java and Java Basics MCQ
Follow the below steps to write and run your first Java Program.
- Install JAVA on your machine or PC
- Setup a Java Path or Java Home under Environment Variables
- Download a good Text Editor or IDE
- Run the program and see Output
[WpProQuiz 49]
Java MCQ
1) What does JVM stands for?
A) Java Variable Machine
B) Java Virtual Machine
C) Java Virtual Mechanism
D) None of the above
Answer [=] 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
Answer [=] D
3) When was first Version of Java i.e Java 1.0 was released?
A) 1991
B) 1994
C) 1996
D) 1999
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] 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
Answer [=] D