i
Oracle
Filter interviews by
I applied via Naukri.com and was interviewed before Sep 2020. There were 3 interview rounds.
I was interviewed before Feb 2021.
Round duration - 60 Minutes
Round difficulty - Medium
This round had 1 question related to DSA and then the majority of the questions were revolving around Java.
Given a binary tree of integers, convert it to a sum tree where each node is replaced by the sum of the values of its left and right subtrees. Set leaf nodes to zero.
...Approach :
1) Build the Sum Tree
1.1) Update the root data with the sum of the left and right children’s data given that the root itself is not null.
1.2) Check the left node and right node. If they are not null, take their sum and update the root data.
1.3) Extend this idea further by making a recursive call on to the left and right subtrees.
2) Do a pre order traversal.
2.1) To keep track of the node data in the preo...
Answer :
1) Garbage Collection in Java is a process by which the programs perform memory management automatically.
2) The Garbage Collector(GC) finds the unused objects and deletes them to reclaim the memory. I
3) In Java, dynamic memory allocation of objects is achieved using the new operator that uses some memory and the memory remains allocated until there are references for the use of the object.
4) When there are no r...
JVM is platform dependent because it takes java byte code and generates byte code for the current operating system. So Java software is platform dependent but Java language is platform independent because different operating system have different JVMs.
Marker interfaces, also known as tagging interfaces are those interfaces that have no methods and constants defined in them. They are there for helping the compiler and JVM to get run time-related information regarding the objects.
Round duration - 60 Minutes
Round difficulty - Medium
In this round, I had 2 questions of DSA where I had to first explain my approach with proper compleixt analysis and then write the pseudo code for both of them. After that, I was asked some questions from Java and MVC architecture.
Design a data structure for a Least Recently Used (LRU) cache that supports the following operations:
1. get(key)
- Return the value of the key if it exists in the cache; otherw...
Answer :
Structure of an LRU Cache :
1) In practice, LRU cache is a kind of Queue — if an element is reaccessed, it goes to the end of the eviction order.
2) This queue will have a specific capacity as the cache has a limited size. Whenever a new element is brought in, it is added at the head of the queue. When eviction happens, it happens from the tail of the queue.
3) Hitting data in the cache must be done in constant ti...
You are provided with two singly linked lists containing integers, where both lists converge at some node belonging to a third linked list.
Your task is to determine t...
Approach (Using 2-pointers) :
1) Initialize two pointers ptr1 and ptr2 at the head1 and head2.
2) Traverse through the lists,one node at a time.
3) When ptr1 reaches the end of a list, then redirect it to the head2.
4) Similarly when ptr2 reaches the end of a list, redirect it the head1.
5) Once both of them go through reassigning, they will be equidistant from the collision point
6) If at any node ptr1 meets ptr2, the...
The different MVC components have the following roles -
1) Presentation: This component takes care of the visual representation of a particular abstraction in the application.
2) Control: This component takes care of the consistency and uniformity between the abstraction within the system along with their presentation to the user. It is also responsible for communicating with all other controls within the MVC system.
3) A...
There is a group of routes called the RouteCollection, which consists of registered routes in the application. The RegisterRoutes method records the routes in this collection. A route defines a URL pattern and a handler to use if the request matches the pattern.
The first parameter to the MapRoute method is the name of the route. The second parameter will be the pattern to which the URL matches. The third parameter migh...
It is possible to import a class or package more than once, however, it is redundant because the JVM internally loads the package or class only once.
Round duration - 60 Minutes
Round difficulty - Medium
This round was inclined towards some Low Level Design Principles and some concepts from MVC.
Tip 1 : Firstly, remember that the system design round is extremely open-ended and there’s no such thing as a standard answer. Even for the same question, you’ll have a totally different discussion with different interviewers.
Tip 2 : Before you jump into the solution always clarify all the assumptions you’re making at the beginning of the interview. Ask questions to identify the scope of the system. This will clear the...
1) The Spring MVC or Spring Web MVC can be defined as a framework that provides a “Model View Controller” (MVC) architecture in the application as well as ready-components implemented for developing adjustable and adaptable web applications.
2) It is actually a Java-based framework intended to build web applications. It works on the Model-View-Controller design approach.
3) This framework also makes use of al...
There are situations where I want to implement some logic either prior to the execution of the action method or right after it. In that scenario, the Action Filters are used. Filters are used to determine the logic needed for executing before or after the action method gets executed. Action methods make use of the action filters as an attribute. Different types of MVC action filter are:
1) Action filter (that implements...
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
A binary tree is balanced if the height of its left and right subtrees differ by at most 1.
A balanced binary tree has a smoother and faster search time than an unbalanced one.
Balancing a binary tree can be done using various algorithms like AVL tree, Red-Black tree, etc.
An example of a balanced binary tree is the AVL tree, where the heights of the left and right subtrees differ by at most 1.
Top trending discussions
Classes can have both implementation and data members, while interfaces can only have method signatures.
Classes can have constructors, interfaces cannot.
Classes can have access modifiers for their members, interfaces cannot.
A class can implement multiple interfaces, but can only inherit from one class.
Interfaces are used to achieve abstraction and multiple inheritance in Java.
Example: Class 'Animal' can have methods li...
posted on 20 Jun 2024
React DOM is a package that provides methods for updating the DOM in response to React components.
React DOM is used to render React components to the DOM.
It provides methods like ReactDOM.render() to render components.
React DOM efficiently updates the DOM when the state of a component changes.
It handles events and updates the DOM accordingly.
React DOM is separate from React itself, allowing for flexibility in rendering
MVC in Rails is a software design pattern that separates the application into three main components: Model, View, and Controller.
Model: Represents the data and business logic of the application.
View: Represents the user interface of the application.
Controller: Acts as an intermediary between the Model and View, handling user input and updating the Model accordingly.
Example: In a Rails application, a User model would ha...
posted on 13 May 2024
I applied via Referral and was interviewed in Apr 2024. There was 1 interview round.
Had a basic coding test with easy-medium questions along with some HR questions
posted on 29 Dec 2022
I applied via Naukri.com and was interviewed in Nov 2022. There were 2 interview rounds.
I applied via Approached by Company and was interviewed in Aug 2021. There were 3 interview rounds.
DS & Algo based programming
Salesforce Apex coding also making use Queue and Recursive algo.
posted on 20 Jun 2024
Write code for micro service
Singleton is a design pattern that restricts the instantiation of a class to one object.
Singleton pattern ensures that a class has only one instance and provides a global point of access to it.
Commonly used in scenarios where only a single instance of a class is needed, such as database connections or configuration settings.
Implementation can involve a private constructor, a static method to access the instance, and a ...
based on 40 reviews
Rating in categories
Senior Software Engineer
2.4k
salaries
| ₹10.1 L/yr - ₹40 L/yr |
Senior Consultant
2.1k
salaries
| ₹9 L/yr - ₹24.6 L/yr |
Principal Consultant
2k
salaries
| ₹10.9 L/yr - ₹36 L/yr |
Senior Member of Technical Staff
1.8k
salaries
| ₹12 L/yr - ₹45 L/yr |
Senior Application Engineer
1.4k
salaries
| ₹9.5 L/yr - ₹30 L/yr |
SAP
MongoDB
Salesforce
IBM