Core Java Interview Questions Part 2/ introduction of java.

Hello Friends, In this blog post(Core Java Interview Questions) I am going to let you know about a few important questions of core java related to the introduction of java.

Core java interview questions covers all the important questions of the topics mentioned above.

These core java interview questions is a great help to remember all the important highlights and important topics from each java chapter.

These interview questions will surely help to understanding a few very confusing concepts in java.

Why pointers are eliminated from java?

The various reasons for elimination of pointer from java are given below.

Most of the time pointers create confusion for the programmer.

A pointer may crash a program easily, for example, when we add two pointers, the program crashes immediately. The same thing could also happen when we forgot to free the memory allotted to a variable and reallot it to some other variable.

Pointers break security. Using pointers, harmful programs like viruses and other hacking programs can be developed.

What is the difference between a function and a method?

A method is a function that is written in a class. We do not have function in java: instead we have method. This means whenever a function is written in java, it should be written inside a class only. But if we take C++, we can write the function inside as well as outside the class. So, in C++, they are called member function not a method.

Which part of JVM will allocate the memory for a java program?

Class loader subsystem of JVM will allocated the necessary memory needed by the java program.

Which algorithm is used by the garbage collector to remove the unused variable or objects from memory?

Garbage collector uses many algorithm but the most commonly used algorithm is mark and sweep.

How can you call the garbage collector?

Garbage collector is automatically invoked when the program is being run, It can also called by calling gc() method of runtime class or system class in java.

What is JIT compiler?

JIT compiler is the part of JVM which increases the speed of execution of a java program.

So this was all about the Core java interview questions in this topic.

These Core java interview questions could be a great help in your college viva, academic study, and any job interview.

In the case of any queries, you can write to us at [email protected] we will get back to you ASAP.

Hope! you would have enjoyed this post about Core Java Interview Question Part 2/ introduction of java.

Please feel free to give your important feedbacks in the comment section below.

Have a great time!


I am a blogger by passion, a software engineer by profession, a singer by consideration and rest of things that I do is for my destination.