logo

CuriousTab

CuriousTab

Discussion


Home Interview Technology Comments

  • Question
  • If a method is declared as protected, where may the method be accessed?


  • Correct Answer
  • A protected method may only be accessed by classes or interfaces of the same package or by subclasses of the class in which it is declared 


  • Technology problems


    Search Results


    • 1. What do you understand by private, protected and public?
    • Discuss
    • 2. What is Thread ?
    • Discuss
    • 3. What is the difference between creating a thread by extending Thread class and by implementing Runnable interface? Which one should prefer?
    • Discuss
    • 4. What are the the different ways for creating a thread?
    • Discuss
    • 5. How does a try statement determine which catch clause should be used to handle an exception?
    • Discuss
    • 6. What is the difference between method overriding and overloading?
    • Discuss
    • 7. What is classloader?
    • Discuss
    • 8. What will be the output of the following code snippet? Object s1 = new String("Hello"); Object s2 = new String("Hello"); if(s1 == s2) { System.out.println("s1 and s2 are =="); }else if (s1.equals(s2)) { System.out.println("s1 and s2 are equals()"); }
    • Discuss
    • 9. What is JDBC ?
    • Discuss
    • 10. What is DriverManager ?
    • Discuss


    Comments

    There are no comments.

Enter a new Comment