Filter interviews by
I applied via Naukri.com and was interviewed in Sep 2019. There were 5 interview rounds.
Top trending discussions
I was interviewed in Jan 2025.
Exception handling is crucial in programming to handle errors and ensure proper execution. The 'finally' block is used to clean up resources, and throwing exceptions allows for error propagation.
Exception handling is used to manage errors and unexpected situations in a program.
The 'finally' block is used to execute code that should always run, regardless of whether an exception is thrown or not.
Throwing exceptions allo...
ACID properties ensure data integrity in transactions. CAP Theorem states that a distributed system can only guarantee two out of three: Consistency, Availability, Partition Tolerance.
ACID properties: Atomicity, Consistency, Isolation, Durability
Example: In a banking application, a transfer of funds should be atomic, consistent, isolated, and durable
CAP Theorem: Consistency, Availability, Partition Tolerance - a distri...
Comparable is an interface used for natural ordering, while Comparator is used for custom ordering in Java Collections.
Comparable interface is used to define the natural ordering of objects. It is implemented by the class whose objects are to be sorted.
Comparator interface is used to define custom ordering of objects. It is implemented by a separate class.
To implement Comparable, the class needs to override the compare...
Generics in Java allow for creating classes, interfaces, and methods that operate on types parameterized at compile time.
Generics provide type safety by allowing compile-time type checking.
They enable code reusability and reduce the need for casting.
Example: List<String> list = new ArrayList<>();
Code to reverse a string using recursion
Create a recursive function that takes a string as input
Base case: if the string is empty or has only one character, return the string
Recursive case: return the last character of the string concatenated with the result of calling the function on the substring excluding the last character
Object comparison with specific fields involves comparing values of selected fields between two objects.
Object comparison can be done by comparing the values of specific fields in two objects.
Fields can be selected based on unique identifiers or criteria for comparison.
Example: Comparing the 'name' field of two person objects to check if they are the same.
Distributed transactions in microservices involve using compensating transactions and event-driven architecture.
Microservices typically use compensating transactions to maintain consistency across multiple services.
Event-driven architecture can help in coordinating distributed transactions by using events to trigger actions in different services.
Implementing distributed transactions in microservices requires careful de...
Aggregator pattern is used in microservices architecture to combine multiple service responses into a single response.
Aggregator pattern helps in reducing the number of client requests by combining multiple service responses.
It can be implemented using a separate service or within an existing service.
Example: A shopping website aggregating product information from different microservices like inventory, pricing, and re
Factory design pattern is a creational pattern that provides an interface for creating objects in a superclass, but allows subclasses to alter the type of objects that will be created.
Factory method pattern defines an interface for creating objects, but lets subclasses decide which class to instantiate.
It promotes loose coupling by eliminating the need to bind application-specific classes into the code.
Example: A car m...
Indexing in a database is a technique to improve the speed of data retrieval by creating a data structure that allows for quick lookup.
Indexing involves creating a separate data structure that contains pointers to the actual data in the database.
Common data structures used for indexing include B-trees, hash tables, and binary search trees.
Indexes can be created on one or multiple columns in a database table to speed up...
My approach involves using load balancing, caching, asynchronous processing, and horizontal scaling.
Implement load balancing to distribute requests evenly across multiple servers.
Utilize caching mechanisms to store frequently accessed data and reduce response times.
Use asynchronous processing for long-running tasks to free up resources for handling more requests.
Implement horizontal scaling by adding more servers to ha...
CQRS pattern in microservices separates read and write operations for improved scalability and performance.
CQRS stands for Command Query Responsibility Segregation
It separates the read and write operations into two different models
Write operations update the data store, while read operations query a separate data store
CQRS can improve performance and scalability by allowing each model to be optimized for its specific t
API Gateway acts as a single entry point for all client requests in a microservices architecture.
API Gateway handles authentication, authorization, rate limiting, and routing of requests to appropriate microservices.
It helps in decoupling client applications from individual microservices, providing a more flexible and scalable architecture.
API Gateway can also perform tasks like request/response transformation, logging...
SQL query to fetch data from two tables using joins
Use the JOIN keyword to combine rows from two tables based on a related column
Specify the columns to select from each table in the SELECT statement
Use the ON keyword to specify the join condition
It was basically two leetcode Questions Mainly from array with some algorithm required to apply and other from LinkedList.
Java-based coding, streams and lambda, design patterns
Low level architecture design principles focus on optimizing performance, efficiency, and resource utilization.
Optimize for performance by minimizing latency and maximizing throughput
Efficiently utilize resources such as memory, CPU, and network bandwidth
Design for scalability and flexibility to accommodate future growth
Use modular and reusable components to promote maintainability and code reusability
Consider security
I applied via Approached by Company and was interviewed in Feb 2024. There was 1 interview round.
A bean in Spring is a Java object that is instantiated, assembled, and managed by the Spring IoC container.
Beans are defined in the Spring configuration file using XML or annotations.
Beans are singleton by default but can be configured as prototype.
Beans can have dependencies injected by the container.
Example: @Component annotation in Spring creates a bean.
Example:
Design a URL shortener system
Use a unique identifier for each long URL to generate a short URL
Store the mapping of short URL to long URL in a database
Implement a redirect mechanism to redirect short URLs to their corresponding long URLs
Consider scalability and performance while designing the system
Use Floyd's Tortoise and Hare algorithm to detect cycle in a linked list.
Initialize two pointers, slow and fast, at the head of the linked list.
Move slow pointer by one step and fast pointer by two steps.
If they meet at any point, there is a cycle in the linked list.
I applied via Approached by Company and was interviewed in Aug 2023. There were 6 interview rounds.
2 coding problems.
One is on Hasmap
second one is on Tree
I applied via Approached by Company and was interviewed before Jul 2023. There were 3 interview rounds.
Mostly dynamic programming and tree based programs
based on 1 interview
Interview experience
based on 3 reviews
Rating in categories
L2 Engineer
72
salaries
| ₹8.3 L/yr - ₹18 L/yr |
Analyst
61
salaries
| ₹4.3 L/yr - ₹12.6 L/yr |
Senior Engineer
54
salaries
| ₹10 L/yr - ₹26.5 L/yr |
Senior Software Engineer
54
salaries
| ₹11.9 L/yr - ₹26.5 L/yr |
Senior Analyst
46
salaries
| ₹5.7 L/yr - ₹21.5 L/yr |
Walmart
Target
Macy's
Kohl's