aspose file tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Doubt in john meyers' question... Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Reply Bookmark "Doubt in john meyers Watch "Doubt in john meyers New topic
Author

Doubt in john meyers' question...

Gabriel Ozeas
Ranch Hand

Joined: Jul 04, 2008
Posts: 30

Hi folks, i have a doubt about modifiers in this question from john meyers



why the compare method can access t1.x and t2.x if they are private? i compile and run this code but no compiler or runtime error appeared...

thxz everyone!
chander shivdasani
Ranch Hand

Joined: Oct 09, 2007
Posts: 206

private members of a class can be accessed by the methods of the same class


Enjoy, Chander
SCJP 5, Oracle Certified PL/SQL Developer
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Doubt in john meyers' question...
 
Similar Threads
collections
One more mock exam question
Comparable or Comparator
Garbage collection output doubt
Please give responses..