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 / prashanth
true
false
The Buffer size of Integer class is -128 to 127
Except this range in all remaining cases a new object will be created.
| Is This Answer Correct ? | 5 Yes | 2 No |
Post New Answer View All Answers
How does finally block differ from finalize() method?
What is the use of parse function in java?
What is a parameter in a function?
What is number data type?
How many bytes is a string in java?
What is unicode in java?
Can an unreferenced object be referenced again?
What is the purpose of garbage collection in java? When is it used?
What do you understand by overloading and overriding in java?
What is a copy constructor in java?
What is preparedstatement in java?
What is pass by value?
What is use of map in java?
What is the difference between reader/writer and inputstream/output stream?
What is string english?