How can a class be accessed, If no access modifiers are
declared?
Answer Posted / ranganathkini
If a class is marked with no access modifiers then it is
given "package" access by default which means it can be
instantiated or subclasses by other classes in the same
package but it is inaccessible to classes outside the same
package.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
For class CFoo { }; what default methods will the compiler generate for you>?
What is the difference between the paint() and repaint() methods in java programming?
Are true and false keywords?
What are the common uses of "this" keyword in java ?
Is java type safe?
What is super in java?
What is the difference between Error, defect,fault, failure and mistake?
What is an image buffer?
What is the original name of java?
What are the differences between wait() and sleep()?
Write down program for following scenario. Use java coding standard. You have array list with some words in it..we will call it as dictionary….and you have a arbitrary string containing some chars in it. You have to go through each word of dictionary and find out if that word can be constructed with the help of chars from arbitrary string given. If you find the word print it else print none.
What is the file type?
Can you give few examples of final classes defined in java api?
What is the disadvantage of synchronization?
how to convert Java project into Maven ?