This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error again ( 4th time, same site ) Mr. Hareet! What will you say?

 
Arijit Daripa
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Mr. Hareet!
One of the questions in
http://www.irixtech.com/java/scjp/mock-exam/practice-test-2 is



Your answer is (a) and (c).
(a) Java is allowing us to assign null to primitives!
(c) Returning from a method with return type null!
 
Ashish Hareet
Ranch Hand
Posts: 375
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Modified option b to be correct option

public String[ ] getNameList( ) {
return new String[ ] { "Him", "Me", "She", "I" };
}
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic