Pages

July 23, 2019

Wissen Technology Interview Questions For Senior Java Developer/ Lead Position

  1. What is the difference between Composition and Aggregation? How can we implement them in Java?
  2. How can we implement Least Recently Used (LRU) Cache using LinkedHashMap? (solution)
  3. What is the use of Builder Design Pattern. (solution)
  4. Explain Observer Design pattern. (solution)
  5. Assume we have an Employee class, which contains employeeName, employeeId (both are Strings) and employeeDateOfJoining(which is date). How can I make employee class Immutable? (solution)
  6. What is the advantage of making a String class Immutable? (solution)
  7. Design your own custom Threadpool executor with minimal functionality?(solution) (GIT:Custom Threadpool executor)
  8. An Employee table has four columns, emp_id, emp_name, salary and mngr_id. Find all the employees, who have a bigger salary than their manager. Answer: SELECT e.emp_name FROM Employee e JOIN Employee m ON e.mngr_id = m.emp_id WHERE e.salary > m.salary;
  9. Find the employee who is getting third higest salary? Answer: SELECT top 1 salary FROM (SELECT top 3 salary FROM Employee ORDER BY salary DESC) Result ORDER BY salary;

No comments:

Post a Comment