File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes problem with clone....... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "problem with clone......." Watch "problem with clone......." New topic
Author

problem with clone.......

sonir shah
Ranch Hand

Joined: Nov 01, 2001
Posts: 435

Answer : It will print "false true"
Can any one explain me why does it print such an answer??
I agree with the second part of the answer i.e(true), But why is ia==ja said to be false??(Since they both are Integer arrays)
Sonir
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12806
    
    5
Oh come on! You already know the answer to that. Think! They are two separate objects! What does == test?
 
jQuery in Action, 2nd edition
 
subject: problem with clone.......