Top 500+ Advanced Java Interview Questions 2020-2021 - 1

Question: 1

What are the supported platforms by Java Programming Languages?

Java runs on a variety of platforms, such as Windows, Mac OS, and the various versions of UNIX/Linux like HP-Unix, Sun Solaris, Redhat Linux, Ubuntu, CentOS etc.

Question: 2

How many types of inheritances does Java support?

Yes, Ok but, basically there are two types of Inheritances are there, they are

Single Inheritance

Multiple Inheritances

And some other Inheritances are there those are

Multi level

Hierarchical

Hybrid and

Java supports only Single Inheritance only.

Question: 3

What is the difference between constructor and method?

Constructor will be automatically invoked when an object is created whereas method has to be called explicitly.

Question: 4

What is the difference between static and non static variables?

A static variables is associated with the class as a whole rather than with specific instances of a class.

Non static variables take on unique values with each object instance.

Question: 5

What are pass by reference and pass by value?

Pass by Reference means the passing the address itself rather than passing the value.

Pass by value means passing a copy of the value to be passed.

Related Questions