| Author |
need explanation on wrapper class
|
praveen kumar
Greenhorn
Joined: Sep 02, 2005
Posts: 4
|
|
can anyone explain me the output of the follwing program: public class Test{ public static void main(String args[]){ Byte b1=new Byte("1"); if(b1.toString()==b1.toString()) System.out.println("true"); else System.out.println("false"); Byte b=new Byte("19"); if(b.toString()==b.toString()) System.out.println("true"); else System.out.println("false"); } } The output is: true false
|
 |
A Kumar
Ranch Hand
Joined: Jul 04, 2004
Posts: 973
|
|
HI CHECK OUT this link... http://www.coderanch.com/t/250475/java-programmer-SCJP/certification/toString-Integer-class Regards
|
 |
 |
|
|
subject: need explanation on wrapper class
|
|
|