Code Pumpkin

Sapient Global Markets Interview Questions – Set 3

Hey everyone, I am writing this article for the people who wants to appear for Sapient Global Markets. I appeared for Senior Application Developer in Sapient Global Markets Bangalore on August 2017. I would Like to share my experience with you guys. I will cover Technical round question and some brief intro of Sapient GM process.

I went through 3 rounds (Technical + Managerial + online Behavioral Test). Over all experience was great and interviewer seems to be very Polite which made my interview process smooth. Before applying be prepared with MultiThreading and Data Structure they focus mainly on these 2 things. So Sapient Global Markets Interview questions are as follows:

  1. How does HashMap work internally? (Answer)
  2. get() and put() method in HashMap?
  3. Rehashing in hashmap?
  4. How to make custome objects as hashMap keys?
  5. Immutable class property? What happens if one of the field in Immutable class is Mutable? How will you achieve Immutability?   (Answer
  6. What is role of serialVersionUID? ref to previous question?
  7. How to store <K,V> in way which maintains insertion order?
     Ans:  Using LinkedHashMap<K,V>. 
  8. Difference between TreeMap and TreeSet?
  9. How TreeMap is different from HashMap?
  10. Put employee object in TreeMap where it is  sorted by lastName? What will happen if we do not provide comparable or comparator implementation.
  11. Write code implement compare() method code for comparing employee lastname.


    public static Comparator<Employee> LastNameComparator = new Comparator<Employee>() 
            public int compare(Employee e1, Employee e2) {
                return  e1.getLastName.compareTo( e2.getLastName);

  12. Reverse singly linked list . Give its time and space complexity?
    1) Iterative Method
    Iterate trough the linked list. In loop, change next to prev, prev to current and current to next.
    Time Complexity: O(n)
    Space Complexity: O(1)

    2)Recursive Method:

       1) Divide the list in two parts - first node and rest of the linked list.
       2) Call reverse for the rest of the linked list.
       3) Link rest to first.
       4) Fix head pointer

    Time Complexity: O(n)
    Space Complexity: O(1)

  13. Find middle element of singly linked list.Give its time and space complexity.
    Ans:  Traverse linked list using two pointers. Move one pointer by one and other pointer by two. When the fast pointer reaches end slow pointer will reach middle of the linked list.
    Time Complexity: O(n)
    Space Complexity: O(1)
  14. How does Garbage Collector works?
  15. How many GC algorithms do you know?
  16. What is permgern space?
  17. Which object except string object are stored in perm gen space?
  18. How to create unchecked custom exception?
    Ans:  By extending RuntimeException Class in your custom exception Class.
  19. Explain Exception Hierarchy?
  20. Difference between wait and sleep?
  21. Explain priorityqueue?
  22. How many concurrent classes have you used?
  23. What is difference between countdownlatch and cyclicbarrier? (Answer)
  24. List down design pattern u have used? explain factory design pattern?
  25. Explain fail- fast and fail safe?
  26. Which java version you are using? explain java 8 features?
  27. What is functional interface?
  28. Which database you are using? Have you used nosql?
  29. What is aggregation and composition?
  30. What are types of indexes? Explain clustered and non clustered index?
  31. Have you used joins, cursor, triggers, stored procedure?
  32. What are design principle? explain them? SOLID?
  33. How you will print "Hello" " Sejal " using 2 thread in concatenation? 
  34. Which tool u r using for webservice? 
  35. How you are creating wsdl? Are you consuming or publishing webservice?
  36. Explain elements of wsdl?
  37. Which spring component you are using?
  38. Explain spring bean life cycle?
  39. What is spring bean scope?
  40. Which transaction you are using?
  41. Have you used JMS?How you are using JMS? 
  42. Expalin Difference between Queue based or Topic based?
  43. Hibernate get and load difference?

Thats all Folks. I hope these set of questions will help you in preparation. Thank you  and All the very Best. 

That's all for this topic. If you guys have any suggestions or queries, feel free to drop a comment. We would be happy to add that in our post. You can also contribute your articles by creating contributor account here.

Happy Learning 🙂

If you like the content on CodePumpkin and if you wish to do something for the community and the planet Earth, you can donate to our campaign for planting more trees at CodePumpkin Cauvery Calling Campaign.

We may not get time to plant a tree, but we can definitely donate ₹42 per Tree.

About the Author

Tags: , , , ,

Comments and Queries

If you want someone to read your code, please put the code inside <pre><code> and </code></pre> tags. For example:
<pre><code class="java"> 
String foo = "bar";
For more information on supported HTML tags in disqus comment, click here.
Total Posts : 124
follow us in feedly

Like Us On Facebook