Synechron Interview Questions – Set 1
Synechron had arranged walk-in drive at Ahmedabad location for multiple opening at Mumbai, Pune and Bangalore location. I have appeared for Sr Java Developer position.
I got a call from Ethos HR consultancy and interview was scheduled at the office of Ethos HR, Ahmedabad. Arrangement by Ethos HR was very poor and unprofessional. However, interviewers were very friendly and good at interviewing.
There were total three rounds. Two technical and One HR round.
First Technical Round
- Do you know about SOLID design principles? Explain.
What is the difference between
ArrayListbe resized? What will be the size of new
HashMapworks internally? Explain
HashMapcalculate Bucket position, if returned HashCode of key is 35 and HashTable array size is just 16?
Can we have multiple
Answer : Yes. HashMap can have multiple
nullvalues and one
nullkey. for more details you can check our article on HashMap Internals.
HashSetwork internally? Which data structure it uses internally?
HashMap. Stores all the element as
HashMapkey and value as static instance of class
– For detailed understanding, please read our article How is HashSet implemented internally in Java?
What is the difference between
HashMapis not thread-safe.
SynchronizedMapis a thread-safe, but it will acquire lock on entire Map in read and write opearations. So at a time only one thread can either read or write in Synchronized Map. Hence it is slower.
ConcurrentHashMapis a thread-safe. Instead of acquireing a lock on entire Map object, it devides map in different segements and each thread can aquire a lock on individual segment. so at a time multiple threads can write in different segments but not in the same segement. Also this lock is required only in write operation. Multiple threads can read concurrently from the same segement.
SynchronizedMapcan have multiple
nullvalues and one
ConcurrentHashMapcan not have any
nullkeys or values.
– For detailed understanding, please read our article Hashtable Vs SynchronizedMap Vs ConcurrentHashMap
- What is the difference between CountDownLatchand CyclicBarrier? (Answer)
- How to create Immutable object? What you will do if one of the field in your immutable class is mutable? (Answer)
Write down a program to implement your own iterator of
- Find a cycle in a linked list.
- Find a first node of that cycle.
- Write a program to print 'Hello World' repeatadly using two threads. Thread 1 should print 'Hello' and Thread 2 should print 'World'
- Where have you used WebServices in your application?
- What are the scope of Spring Bean?
- What is the default scope of Spring Bean?
- What is prototype scope in Spring?
- Explain Spring MVC Execution Flow.
- Explain Spring Bean Life cycle.
Explain any one use case of Spring
- Difference between auto wire by Type and auto wire by Name.
What is the use of
- Explain all types of joins in database.
- What is SQL Injection? Which feature of JDBC can we use to prevent SQL Injection?
- For below given SQL Table
Write a query to fetch result as below
After I clear first technical round, they have scheduled a HR discussion. They have asked me about various behavioural questions like
- Why are you looking for a Job change?
- Why do you want to relocate to Bangalore?
- Why do you want to join Synechron?
- Have you read reviews about Synechron?
- There were so many negative reviews about Synechron in Glassdoor. Why you still want to join Synechron?
- where do you see yourself in 5 years?
- What are the two things which you don't like about your current organization?
- If we will give you an good offer, and after that your current organization will also agree to give you a good salary hike. Will you join Synechron or will choose to serve in current Organization?
Second Technical Round (Telephonic)
After HR Round, they have scheduled one more technical telephonic round.
- What all things will you take care, if you are using serialization?
What will happen, if I will not declare
SerialVersionUIDin a class which implements
- How have you used serialization in your project?
- What is the difference between Immutable object and Mutable Object?
- When you will use Immutable objects in your application?
- What is CyclicBarrier?
Have you ever used CyclicBarrierin your application? If Yes, what have you implemented using
Write a java function which accepts
Mapas input and outputs another
input Map : Map<Student,Marks>
output Map : Map<Student,Grades>
conditions for output Map :
1. Grades Calculation:
if marks > 90, then A Grade
if 80 < marks < 90, then B Grade
if 70 < marks < 80, then C Grade
if 60 < marks < 70, then D Grade
if 50 < marks < 60, then E Grade
2. Map should only contain Students having marks more than 50.
3. Map should be sorted based on Grades.
- What is the use of dispatcher servlet in Spring MVC.
- What all database constraint do you know?
- Is it possible to create Composite Unique Key? Or It can be created only on one table?
- Difference between clustered Index and Non clustered Index.
- What is First Level Caching in Hibernate?
How you will create
OneToManyrelationship in Hibernate?
- What are the different state of Hibernate POJO?
- What is transient state?
- What is Cascade Attribute In Hibernate?
This article is contributed anonymously by one of the CodePumpkin user. If you would also like to contribute your article or share interview experiences, you can create contributor account with CodePumpkin by clicking here or you can send us a mail at email@example.com.
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: ArrayList, Collection Framework, Collections, Concurrency, Core Java, DataStructure, HashMap, Java, Linkedlist, Multithreading, SinglyLinkedList, Synchronization
Comments and QueriesIf 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"; </code></pre>For more information on supported HTML tags in disqus comment, click here.