alright, I have been aware of private, protected, and public access modifiers but just this week I discovered that there is also the default access modifier in Java. In case none of the three p-- modifiers is mentioned in a method header or field declaration, they seem to have the default access modifier. My idea is that one should be aware of it but that it is not very necessary to use. Rather, a coder should always specify one of the p- modifiers for every method/field. or am I wrong? If yes, could anyone give me some idea why one would want to use a default modifier?

This article has been dead for over six months. Start a new discussion instead.