Filter interviews by
I applied via Recruitment Consultant and was interviewed before Jun 2019. There were 8 interview rounds.
Top trending discussions
I applied via LinkedIn and was interviewed in Jun 2021. There were 4 interview rounds.
I applied via Company Website and was interviewed in Apr 2021. There was 1 interview round.
I applied via Campus Placement and was interviewed before Jul 2020. There was 1 interview round.
Island Perimeter and Number of Provinces. Basic Leetcode question
I applied via Naukri.com and was interviewed in Oct 2021. There were 4 interview rounds.
I applied via Job Portal and was interviewed in Jun 2021. There were 5 interview rounds.
Oops concepts are fundamental to object-oriented programming. They help in creating modular and reusable code.
Encapsulation - hiding implementation details of an object from the outside world
Inheritance - creating new classes from existing ones, inheriting their properties and methods
Polymorphism - ability of objects to take on many forms, depending on the context
Abstraction - focusing on essential features of an objec
Multiple inheritance is not allowed in Java to avoid the diamond problem.
Java supports multiple interface inheritance to achieve the same functionality.
Diamond problem occurs when a class inherits from two classes with a common method.
Java prioritizes single inheritance to maintain simplicity and avoid ambiguity.
Arrays are fixed in size while ArrayLists can dynamically grow and shrink.
Arrays are of fixed size while ArrayLists can be resized dynamically.
Arrays can hold primitive data types and objects while ArrayLists can only hold objects.
Arrays are faster for accessing elements while ArrayLists are faster for adding and removing elements.
Arrays use square brackets [] to declare while ArrayLists use angle brackets <>.
Example: ...
Java collections are classes and interfaces that provide a way to store and manipulate groups of objects.
Java collections include List, Set, Map, Queue, and their respective implementations
They provide methods for adding, removing, and accessing elements
Examples include ArrayList, HashSet, TreeMap, and PriorityQueue
Time theta is a measure of the worst-case time complexity of an algorithm.
It is used to analyze the performance of algorithms.
It represents the maximum amount of time an algorithm takes to complete.
It is denoted by the symbol Θ(n).
Bubble sorting is a simple sorting algorithm that repeatedly steps through the list, compares adjacent elements and swaps them if they are in the wrong order.
Bubble sort is a comparison-based algorithm
It works by comparing each pair of adjacent elements and swapping them if they are in the wrong order
The algorithm repeats this process until no more swaps are needed
It has a worst-case and average-case complexity of O(n^...
Code to generate a random number between 15-25
Use Math.random() to generate a random number between 0-1
Multiply the result with the range (25-15) and add the minimum value (15)
Use Math.floor() to round down the result to an integer
I applied via Recruitment Consultant and was interviewed in Jun 2021. There were 3 interview rounds.
Fail fast prioritizes speed of detection and resolution, while fail safe prioritizes safety and minimizing harm.
Fail fast approach is commonly used in agile development where quick feedback is essential
Fail safe approach is commonly used in critical systems such as medical devices or aviation
Fail fast can lead to more errors and instability if not properly managed
Fail safe can lead to slower response times and increase...
TCS
Accenture
Wipro
Cognizant