what is the output public class Barclays { static class A{ A(){ f(); } public void f(){ System.out.println("A ctor"); } } static class B extends A{ B(){ f(); } public void f(){ System.out.println("B ctor"); } } public static void main(String[] args) { B b = new B(); b.f(); A a = new A(); a.f(); } }
Java Software Developer Interview Questions
26,902 java software developer interview questions shared by candidates
Yeah, it is not thread safe, you can call it just a certain number of times, what would you do? There is some feature in the language, but I'm trying to see what you think.
1. Implement Comparable Interface? 2. Write a Employee class and sort its properties age and Emp name? 3. How actually hashmap works in Java? 4. How the size of ArrayList grows dynamically?
how are you? Have you ever worked
Draw merge sort on paper.
Program : find duplicate string from list
You have a birthday cake and have exactly 3 cuts to cut it into 8 equal pieces. How do you do it?
Write a method to remove even numbers from list without using any other collection.
program
What is the difference between String Builder and String Buffer
Viewing 311 - 320 interview questions