"Can one object access a private variable of another object
of the same class ? "
TRY THIS CODE:
Caution: This is only applicable when you are accessing private member using the reference variable of the class from main() method defined in the same class. Try this from other class, you will get compilation error.
Is this answer to your doubt?
Thanks and Regards,
cmbhatt
[ April 05, 2007: Message edited by: Chandra Bhatt ]