Java Sample Codes and Articles
Best Java Article and Sample codes that Needed.
Pages
Home
Oops Concepts
Java BuzzWords
Interview Questions
Monday, July 18, 2011
Java Questions - 15
What can go wrong if you replace && with & in the following code:
String a=null; if (a! =null && a.length ()>10) {...}
A single ampersand here would lead to a NullPointerException.
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment