What is the difference between Integer and int?

Answer Posted / k.santosh kumar

int is a primitive data type , where as Integer is a class
which encapsulates the primitive int data type and
represents in terms of object.

Is This Answer Correct ?    35 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of default method in interface in java? Explain

549


What is final, finally, finalize?

596


How finally used under exception handling?

516


What is the byte order of byte buffer?

563


What is udp in java?

533






What is the base class for error and exception?

555


What do you understand by the term wrapper classes?

546


How many bits is a string in java?

577


What happens when you invoke a thread’s interrupt method while it is sleeping or waiting?

573


What is an exception in java?

647


Does java return by reference?

537


What is a classloader in java?

535


How to avoid memory leak in java?

596


Can list be null in java?

579


Is singleton thread safe in java?

549