public class Test

{

public static void main(String ar[])

{

Integer a = 10;

Integer b =10;

Integer c = 145;

Integer d = 145;

System.out.println(a==b);

System.out.println(c==d);

}

}

Answer Posted / ravi

using "Singletone Design pattern" we can prevent class creating multiple objects.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Enlist few advantages of inheritance?

572


Can Exception handling we can handle multiple catch blocks?

637


What do you understand by the term singleton?

573


Can a main method be declared final?

575


How do you create immutable object in java?

533






Where can i get Latest SUN Certification Dumps and what are the Sun Certification Codes that are available, Im new to JAVA, so please gimme info as i need to write J2EE - Core Java Certification

1365


Difference between == and .equals() ?

568


What is a layout manager and what are different types of layout managers available in java awt?

712


What 4 doubled?

533


What are the main concepts of oops in java?

585


Explain access modifiers in java.

574


What is a arraylist in java?

549


What is the use of jtable?

640


What are the main uses of the super keyword?

547


Explain the importance of join() method in thread class?

634