Win a copy of Murach's Python Programming this week in the Jython/Python forum!
    Bookmark Topic Watch Topic
  • New Topic

Why we can't declare private and protected as access specifiers for a class  RSS feed

 
Ramesh Pappala
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Report post to moderator
Why we can't use private and protected as access specifiers for a class.
Could you give me an example.
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24215
37
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Report post to moderator
Because you can't. Why can't a variable be declared as both "int" and "double?" Same reason: because it can't.

Please don't start new threads to ask follow-on questions from other threads -- we already discussed this here. I'm going to close this thread; followups in the original thread, please.
 
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!