Core Java Interview Questions
Questions Answers Views Company eMail

1.what is the exact difference between applet and frame? 2.Do we use main method in frames?

5 24541

diff between abstract methods and interfaces with programing (code) example?

2 4476

Is it compulsory to have atleast one abstract method in abstract class?

10 20977

public class Garbage { int a=0; public void add() { int c=10+20; System.out.println(c); System.out.println(a); } public static void main(String args[]) { Garbage obj=new Garbage(); System.gc(); System.out.println("Garbage Collected"); obj.add(); } } Above is a code in java used for garbage collection. object obj has been created for the class Garbage and system.gc method is called. Then using that object add method is called.System.gc method if called the obj should be garbage collected?

6 6556

Why cant we define System.out.println() inside a class directly?

5 10037

If all the methods in abstract class are declared as abstract then what is difference between abstract class and in interface?

Infosys, Synechron,

8 12857

why marker interfaces are there in java

Digital Group,

4 7483

How to validate the request (Eg:user name and password) in session(http session)? not in LDAP server ?

Saksoft,

1 5130

In C we use only compiler. Why java uses both compiler and interpreter? What is its significance?

5 16440

What are Advatages of Overloading and Overridding.

TCS, Wipro,

8 23533

Can we declare static variables in JSP page.

TCS,

3 22631

wHAT IS DEFAULT SPECIFIER IN JAVA wHAT IS DEFAULT CONSTRUCTOR IN JAVA wHAT IS DEFAULT METHOD IN JAVA

IBM,

12 15886

write java code to print second max number in the array

Huawei, IBAB,

12 20705

how to call One constructor from another;

Innodata Isogen,

10 14953

Write java code to print "Hello how are you" Thread1 should have "Hello" Thread2 should have "how are you" both the threads should start at the same time

Huawei,

4 8468


Post New Core Java Questions

Un-Answered Questions { Core Java }

What are the four versions of java?

560


What does split function do in java?

547


How to sort numbers in java without array?

542


Difference between ‘is-a’ and ‘has-a’ relationship in java?

549


What is the difference between stringbuffer and stringbuilder class?

582






Which collection is sorted in java?

556


what is anonymous class in java?

559


what is optional in java 8?

575


how is final different from finally and finalize in java?

616


What is unicode with example?

618


How can we find the sum of two linked lists using stack in java?

580


What is skeleton and stub? What is the purpose of those?

550


What are packages in java?

573


Explain about strings in java?

628


Write a program to print the pattern given below

508