Sunday, May 6, 2018

Markit Java Interview Questions

Core Java

  1. Explain the concept of String immutability. What is String pool. How will you create your own String like class.
  2. Explain Serialization. Overriding writeObject method.
  3. What is a class loader.
  4. What are Java locks. class level lock vs lock on objects.
  5. HashMap, ConcurrentHashMap, TreeSet internal implementation.
  6. What are Cyclic barrier and countdown latch.
  7. Implement producer-consumer problem.
  8. How to make a Lock object wait for lock.

Algorithm and Design

  1. You have an input stream of millions of numbers. Which is the suitable data structure for this kind of situation.
  2. He asked me about "Hashing" concept and how is it implemented in java.
  3. Design your own Queue, PriorityQueue(using heap).
  4. Program to find the highest prime number less than a given number.
  5. Design a stack using linked list
  6. Write a program to implement a binary search tree and print the elements in-order.

Design Patterns

  1. Discussion on singleton design pattern:- lazy initialization, eager initialization, also using inner classes. Difference between design patterns. why is one better than another.

Spring

  1. which one is better constructor injection or setter injection.

Misc

  1. What is Left Outer Join.
  2. SQL question including joins, group by
  3. 1 puzzle: there is a 2d array. the numbers in the array increase as you go down and as you move from left to right. find any given number with minimum complexity.
  4. A probability question (probability of getting minimum two 3’s if i roll 2 dice).
  5. why do I want to leave my current organization etc.

    You can buy my ebook for complete collection of questions and answer of Java Interview Questions
    https://books.shunyafoundation.com/to/sku2


No comments:

Post a Comment

Your comment will be published after review from moderator