Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
18 views

Java Topics

Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views

Java Topics

Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 8

SYNECHRON

1. OOPS Concepts
a. A.P.I.E.
b. SOLID
c. Class design
d. HATEOS
e. ACID
f. DRY

2. Core Java

a. Abstract Class
b. Inner class / static inner class
c. Immutable class
d. Interface
e. Marker Interface
f. Exception handling
g. Garbage Collection
h. Class loader/ static and dynamic loading
i. Comparable / Comparator Interface
j. String pool / String Buffer/ String Builder
k. Constructor chaining / in case of abstract class/ interface
l. This and super keywords
m. Serialization
n. Iterator / List Iterator
o. Rules of overloading and overriding
p. Reflection
q. Exception Hierarchy and finally Method, ConcurrentModificationException
r. Pass by value / pass by reference
s. Locking(class level vs instance level)
t. Synchronization
u. Locking mechanisms
v. Serializable & Externalizable and cloanable Interfaces
w. Finalize/clone method of object class

3. Collection Framework(internals)
a. Array / Array List
b. Linked List
c. Vector (rarely asked)
d. Hash Map
e. hash Table
f. Linked Hash Map

Sensitivity: Internal & Restricted


g. Tree Map
h. Sorted Map
i. WeakHashMap
j. All kinds of Sets/ Hash Set/Tree Set
k. LinkedHashSet
l. Stack / Queue/ Priority Queue/ Blocking Queue
m. Condition Interface
n. Fail safe and fail fast iterator
o. CopyOnWriteArrayList
p. ConcurrentSkipListMap
q. ConcurrentHashMap
r. Collections.unmodifiableCollection()

4. Multithreading and Concurrency


a. Thread lifecycle and basics
b. Volatile
c. Synchronize
d. Race condition
e. Deadlocks
f. BlockingQueue / Producer Consumer problem
g. Synchronizers like CyclicBarrier, CountdownLatch
h. Phaser
i. Atomic classes

5. Java 8 topics

6. Design Patterns / Sorting Algorithms


a. Singletons
b. Visitor
c. Template
d. Decorator
e. Strategy
f. Observer
g. Façade /session Façade
h. Factory /Abstract Factory
i. DAO

7. Spring Core
a. Bean Factory
b. Application Context
c. Bean Life Cycle
d. Init / destroy methods
e. Bean Listeners

Sensitivity: Internal & Restricted


f. Processors
g. Scopes
h. Loading mechanisms
i. IOC

8. Database (SQL/PLSQL)
a. DDL
b. DML
c. Delete/truncate/Drop
d. Union / Union All
e. Index/ clustered- non clustered index (including implementations at DS level)
f. Procedure
g. Group by/ having
h. Count(*) Max , Avg, etc
i. Join (types of joins)
j. Primary Kay / Unique Key
k. Isolation levels
l. ACID properties

9. Java Performance Tuning


a. GC algorithm names only
b. Heap memory settings
c. strong, soft, weak and Phantom reference
d. Stack and Heap Concept

10. Analytical/Logical /Scenario Based questions.


a. LRU dictionary or Cache
b. ATM/Library/HR dept design
c. Parking allocation
d. Find most frequently used word from text file
e. Sorting 10 MB file using 1 MB memory
f. 1 billion cellphone numbers to finds duplicates
g. Find duplicate number in Integer Array
h. Identify palindrome
i. Fibonacci series printing using recursive
j. Calculate factorial using recursive and iterative
k. Implement single elevator , double elevator
l. Simulate DVD renting system
m. etc

Sample questions below:

Sensitivity: Internal & Restricted


Question Set 1

1. Design a stack that supports getMin() in O(1) time and O(1) extra space.

2. Program for n’th node from the end of a Linked List

3. Semaphore in java 8, print odd and even number using semaphore

4. How ArrayList works internally in Java 8

5. find second largest number in array without sorting in java

6. Sort an array of 0s, 1s and 2s

7. Reverse a linked list

8. Garbage collection algorithms

9. Implement two stacks in an array

10. Producer-Consumer solution using threads in Java

Question Set 2

1. Implement database connection pooling using semaphore

2. Countdown latch/cyclic barrier -explain, difference between cyclic barrier and countdown
latch

3. How HashMap works internally in Java 8

4. Function to check if a singly linked list is palindrome

5. Atomic variable -How it works internally

6. Difference between Callable and Runnable

7. Detect and Remove Loop in a Linked List

8. CopyOnWriteArrayList implementation

9. Find first unique character in a String

Sensitivity: Internal & Restricted


10. Implement Multithreading application which demonstrates deadlocks and how to avoid
deadlocks.

Question Set 3:

1. Find position of an element in a sorted array of infinite numbers

2. How ConcurrentHashMap works internally in Java 8

3. BlockingQueue-Expalin, implement own ArrayBlockingQueue

4. ReentrantLock implementation

5. Intersection point of two Linked Lists.

6. Creating custom exceptions

7. Design a vending machine

8. Java Reference- Soft, Weak, Strong and Phantom

9. Sort an array of 0s, and 1s

10. Different and best approach for Singleton Pattern

Queue Set 4:

1. Search an element in a sorted and rotated array

2. How TreeSet works internally in Java 8

3. UnModifiable collection own implementation

4. Java 8 new features

5. largest-sum-contiguous-subarray

6. Tree traversal with implementation [preorder, postorder, inorder and mirror]

7. Design multi-level parking system

8. Map sort by value

Sensitivity: Internal & Restricted


9. Design Principle

10. find the middle element in a linked list

11. Implement StringPool -Flyweight Design Pattern

MORGAN-STANLEY & Synechron


12. Design a e-commerce application and how you will do it with micro services
architecture. (along with what all APIs you’ll expose)
13. Why microservices ?
14. HATEOS
15. Program for checking given integer is odd or even
public boolean isOdd(int n){
if(n%2==1)
return true;
else
return false;
}

This program will not work sometimes. Why?

16. You have a computation heavy CPU and one of your jobs is taking 15s to complete
(which is much longer than expected). Can you improve it and how?
(using threads and executer service)

17. Observer design pattern and application


18. Hashtable vs concurrent hashmap
19. Hashmap internal implementation (underlying data structure) and enhancement in java
8 ( Node class, array called table, Entry)
20. Detection of loop in linked list and how to resolve it
21. Enhancements introduced in Spring 5 and Hibernate 4
22. You have an Employee class (Id,name, department, age). U are given a list of employees.
From the list create a new list which had details of all employees whose age is greater
than 30. (Use java 8 concepts)
(stream api with filter)
23. Pre defined Functional interfaces in Java 8
24. Filter method of stream api uses which predefined interface
25. SOLID principles in java
26. DRY Don’t repeat yourself
27. When to use concurrent hashmap over hashmap
28. Lock stripping

Sensitivity: Internal & Restricted


29. Executer services and types of thread pools
30. We have submitted a 1000 tasks and thread pool of 10. How it will work? Internally
where will we put the tasks?
31. Count down latch and cyclic barrier
32. Linked list implementation
33. Quick sort algorithm
34. Binary search tree
35. Singleton- thread safe version.
36. Hash Set
37. Spring bean injection- types
38. Types of autowiring
39. AOP (Before, After, AfterThrowing, Around)
40. Controller advice
41. Qualifier annotation
42. Spring 5 new annotation to tackle autowiring by type confusion
43. Types of inheritance strategies in hibernate
44. Named query
45. Path param vs Query param
46. Is there any limit to the number of Query param? How are they separated from each
other in URL
Fidelity

1. Java 7 new features


2. Java 8 new features
3. Try with resource block
4. Can any resource be given inside try. What is the criteria that resources should fulfill?
5. Spring bean lifecycle
6. Spring bean scopes
7. If Parent bean has scope Singleton inside which we have a reference to another bean
which has scope prototype, how will it behave?
8. Executer service. Why we need it?
9. Runnable Vs Callable
10. execute() Vs submit()
Accenture

1. Singleton design pattern, under what circumstances singleton won’t be singleton?


2. Behavior of Singleton object under Serializable
3. Behavior of Singleton object under Clonable
4. We have try catch finally blocks. How it will behave if we exit using exit(0) in try?
5. There are 3 nested inner loops. If we want to exit from inner most loop to outside of all
loops in a single step, what should we use?
6. Multiple catch blocks, order in which exception should be caught?

Sensitivity: Internal & Restricted


7. Java 7 enhancement of catch block (using | (pipeline))
8. Factory, Decorator, Chain of command design patterns
9. How your api will handle outOfMemory errors
10. Performance improvement for hibernate
Ondot

1. Inside your thread’s run method if you throw an exception, what will happen? Is it
possible? Who will handle the exception?
2. How you will access database from shell script
3. Hibernate Spring integration
4. Hibernate performance tuning
5. Suppose you have a composite key in db. How you will update one of the columns which
make up the composite key? Is it possible? If yes, Write the sql stmt for that
6. Transaction API
7. Exception handling in Spring MVC
8. JMS and rabbitmq
9.

Sensitivity: Internal & Restricted

You might also like