aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Need help Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Need help" Watch "Need help" New topic
Author

Need help

kevin jia
Ranch Hand

Joined: Jul 13, 2000
Posts: 38
Hi,gurus
Could anyone explain , why the answer for following question is false.
public class Q9 {
public static void main(String[] args) {
Byte b1 = new Byte("127");
if(b1.toString() == b1.toString()) {
System.out.println("True");
} else {
System.out.println("False");
}
}
}
thanks !
Ajith Kallambella
Sheriff

Joined: Mar 17, 2000
Posts: 5782
Read the exact same discussion here and here!
Ajith


Open Group Certified Distinguished IT Architect. Open Group Certified Master IT Architect. Sun Certified Architect (SCEA).
kevin jia
Ranch Hand

Joined: Jul 13, 2000
Posts: 38
thanks Ajith.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Need help