What is the difference between Integer and int?
Answer Posted / janet
Integer is a class defined in the java.lang package,where
as int is a primitive data tyep defined in the java
language itself.Java doesn't automatically convert from one
to the other.
Integer can be used as an argument for a method that
requires an object,where as int can be used for
calculations.
Is This Answer Correct ? | 59 Yes | 9 No |
Post New Answer View All Answers
What is the size of arraylist in java?
What are the string methods in java?
What is the use of inner class?
Can we sort a map in java?
What are wrapped classes in java programming?
How can we make a class singleton?
what is the final keyword denotes in java?
Explain about abstract classes in java?
What is difference between == equals () and compareto () method?
Can we change the scope of the overridden method in the subclass?
Is java platform independent?
What is difference between call by value and call by reference?
What is this keyword used for?
What is a percentage sign called?
What is a variable declaration?