Add office photos
Engaged Employer

Oracle

3.7
based on 5.2k Reviews
Video summary
Filter interviews by

600+ GAVS Technologies Interview Questions and Answers

Updated 24 Feb 2025
Popular Designations

Q301. What is java and explain oopes concept

Ans.

Java is a popular programming language used for developing various applications. OOPs (Object-Oriented Programming) is a programming paradigm based on the concept of objects.

  • Java is a class-based, object-oriented programming language.

  • OOPs concepts include encapsulation, inheritance, polymorphism, and abstraction.

  • Encapsulation is the bundling of data and methods that operate on the data into a single unit.

  • Inheritance allows a class to inherit properties and behavior from anoth...read more

Add your answer

Q302. How is kubernetes cluster is exposed to internet ?

Ans.

Kubernetes cluster can be exposed to the internet using various methods.

  • One way is to use a LoadBalancer service type to expose the cluster to the internet.

  • Another way is to use an Ingress controller to route traffic from the internet to the cluster.

  • A third way is to use a NodePort service type to expose the cluster to the internet.

  • It is important to secure the cluster by using authentication and authorization mechanisms.

  • Tools like cert-manager can be used to manage SSL certi...read more

Add your answer

Q303. What is networking ? explain in your own words

Ans.

Networking is the process of connecting devices and systems to share resources and communicate with each other.

  • Networking involves the use of hardware and software to connect devices and systems.

  • It allows for the sharing of resources such as files, printers, and internet connections.

  • Networking also enables communication between devices and systems, allowing for the exchange of data and information.

  • Examples of networking technologies include Ethernet, Wi-Fi, and Bluetooth.

  • Netw...read more

Add your answer

Q304. Write code to emulate Producer/Consumer Problem

Ans.

Emulate Producer/Consumer Problem using code

  • Create a shared buffer between producer and consumer

  • Use synchronization mechanisms like mutex or semaphore to control access to the buffer

  • Implement producer and consumer functions to add and remove items from the buffer respectively

Add your answer
Discover GAVS Technologies interview dos and don'ts from real experiences

Q305. Write down the code for LCA of a binary Tree.

Ans.

Code for finding the Lowest Common Ancestor (LCA) of a binary tree.

  • Start by checking if the root is null or equal to either of the given nodes. If so, return the root.

  • Recursively search for the LCA in the left and right subtrees.

  • If both nodes are found in different subtrees, return the root as the LCA.

  • If both nodes are found in the same subtree, continue searching in that subtree.

View 1 answer

Q306. Find the sq root for a number upto 2 decimal places

Ans.

Use a built-in function or algorithm to find the square root of a number up to 2 decimal places.

  • Use a programming language's built-in function like sqrt() in Python or Math.sqrt() in JavaScript to find the square root of a number.

  • If a built-in function is not available, implement an algorithm like Newton's method to approximate the square root.

  • Round the result to 2 decimal places using a function like round() or toFixed().

Add your answer
Are these interview questions helpful?

Q307. Find the longest path in a binary tree. (Leaf to Leaf)

Ans.

To find the longest path in a binary tree (leaf to leaf), we need to perform a depth-first search and keep track of the maximum path length.

  • Perform a depth-first search on the binary tree, keeping track of the maximum path length encountered so far.

  • At each node, calculate the maximum path length by adding the maximum left and right subtree depths.

  • Update the maximum path length if the current path length is greater.

  • Repeat this process for all nodes in the binary tree to find t...read more

Add your answer

Q308. What is two node rac with two node Dataguard

Ans.

Two node RAC with two node DataGuard is a high availability solution for Oracle databases.

  • Two node RAC provides high availability by allowing multiple instances to access a single database simultaneously.

  • Two node DataGuard provides disaster recovery by maintaining a standby database that can take over in case of a primary database failure.

  • Combining the two creates a highly available and disaster-resistant solution for Oracle databases.

  • In this setup, each node in the RAC has a...read more

Add your answer
Share interview questions and help millions of jobseekers 🌟

Q309. Write an SQL query to copy the structure of a table to another table, but without copying data

Ans.

SQL query to copy table structure without data

  • Use CREATE TABLE AS SELECT statement

  • Include WHERE clause to avoid copying data

  • Example: CREATE TABLE new_table AS SELECT * FROM old_table WHERE 1=0

Add your answer

Q310. What do you like about Oracle?

Ans.

I appreciate Oracle's robust and reliable software solutions.

  • Oracle's software is known for its scalability and performance.

  • Their database management system is widely used and trusted by many organizations.

  • Oracle's cloud offerings provide a comprehensive suite of services for businesses.

  • Their commitment to innovation and staying ahead of industry trends is impressive.

Add your answer

Q311. Find the highest element from a BST and implement insertion operation of BST.

Ans.

To find the highest element in a BST, perform a right traversal until reaching the rightmost leaf node.

  • Perform a right traversal starting from the root node until reaching the rightmost leaf node to find the highest element.

  • Implement the insertion operation by comparing the value to be inserted with each node and traversing left or right accordingly.

  • Ensure that the BST property is maintained during insertion by placing smaller values to the left and larger values to the right...read more

Add your answer

Q312. How to use JAVA code in Oracle BPEL

Ans.

To use JAVA code in Oracle BPEL, you can create a Java Embedding activity within a BPEL process.

  • Create a Java Embedding activity within the BPEL process

  • Write the Java code within the Java Embedding activity

  • Compile the Java code and deploy the BPEL process

Add your answer

Q313. design hashmap from scratch

Ans.

Designing a hashmap from scratch

  • A hashmap is a data structure that allows for efficient key-value pair storage and retrieval

  • It typically uses an array and a hashing function to map keys to array indices

  • Collision handling techniques like chaining or open addressing may be used

  • Operations like insert, delete, and search can be implemented using the hashmap

  • Example: Designing a hashmap to store student records with their roll numbers as keys

Add your answer

Q314. how many zero's in the right side of 21!

Add your answer

Q315. How to handle multiple projects at a time?

Ans.

Prioritize tasks, set deadlines, communicate effectively, delegate when possible.

  • Prioritize tasks based on deadlines and importance.

  • Set clear deadlines for each project to stay on track.

  • Communicate effectively with team members and stakeholders to provide updates and gather feedback.

  • Delegate tasks to team members when possible to lighten the workload.

  • Use project management tools to stay organized and track progress.

  • Example: Create a project timeline with milestones for each p...read more

View 1 answer

Q316. program to print the middle of a given linked list

Ans.

Program to find and print the middle element of a linked list

  • Traverse the linked list using two pointers - one moving one node at a time and the other moving two nodes at a time

  • When the faster pointer reaches the end of the list, the slower pointer will be at the middle element

  • Print the value of the middle element

Add your answer

Q317. Graph basic level implementation

Ans.

Graph implementation involves creating nodes and edges to represent data and relationships.

  • Nodes represent data points and edges represent relationships between them

  • Graphs can be directed or undirected

  • Common graph algorithms include BFS, DFS, and Dijkstra's algorithm

Add your answer

Q318. Design a University Software Portal (System Design).

Ans.

A University Software Portal for students, faculty, and staff to access academic resources and information.

  • User authentication for students, faculty, and staff

  • Dashboard with personalized information and notifications

  • Course registration and scheduling

  • Access to grades, transcripts, and academic records

  • Online library resources and research databases

  • Communication tools for students and faculty (e.g. messaging, forums)

  • Integration with learning management systems (e.g. Moodle, Blac...read more

Add your answer

Q319. Largest element in window size K

Ans.

Find the largest element in a window of size K in an array.

  • Iterate through the array and maintain a deque to store the indices of elements in decreasing order.

  • Remove indices from the front of the deque that are outside the current window.

  • The front of the deque will always have the index of the largest element in the current window.

Add your answer

Q320. Merge two sorted linked lists

Ans.

Merge two sorted linked lists

  • Create a new linked list to store the merged list

  • Compare the first nodes of both lists and add the smaller one to the new list

  • Move the pointer of the added node to the next node

  • Repeat until one of the lists is empty, then add the remaining nodes to the new list

Add your answer

Q321. Explain 8 queens algorithm

Ans.

8 Queens Algorithm is a backtracking algorithm to place 8 queens on a chessboard without attacking each other.

  • The algorithm places one queen in each column, starting from the leftmost column.

  • If a queen can be placed in a row without attacking another queen, it is placed there.

  • If no such row exists, the algorithm backtracks to the previous column and tries a different row.

  • The algorithm continues until all 8 queens are placed on the board without attacking each other.

  • The algori...read more

Add your answer

Q322. Write a program to separate strong for special characters

Ans.

Program to separate strong for special characters in an array of strings

  • Iterate through each string in the array

  • For each string, iterate through each character

  • Check if the character is a special character and separate it into a new string if it is

Add your answer

Q323. Distributed memory - cache consistency problem, issues and solutions

Ans.

Distributed memory cache consistency problem arises when multiple processors access the same data stored in a distributed memory system.

  • Cache coherence protocols like MESI (Modified, Exclusive, Shared, Invalid) are used to maintain consistency among caches in a distributed memory system.

  • Invalidation-based protocols involve invalidating a cache line in all other caches when one cache writes to it.

  • Update-based protocols involve updating all copies of a cache line in different c...read more

Add your answer

Q324. System design of hotel management system

Ans.

A hotel management system involves designing a software system to handle reservations, check-ins, check-outs, room assignments, billing, and other hotel operations.

  • Consider the different modules needed such as reservation management, room assignment, billing, and reporting

  • Design a user-friendly interface for both staff and guests

  • Implement features like online booking, room availability tracking, and payment processing

  • Ensure data security and privacy measures are in place to p...read more

Add your answer

Q325. 1. Write code for producer consumer problem.

Ans.

Producer consumer problem solution code

  • Use synchronized keyword or locks to ensure thread safety

  • Use wait() and notify() methods to coordinate between producer and consumer threads

  • Use a shared buffer to store data produced by producer and consumed by consumer

  • Example: https://www.geeksforgeeks.org/producer-consumer-solution-using-threads-java/

Add your answer

Q326. a robot that cleans the whole room

Ans.

A robot that cleans the whole room is a useful tool for maintaining cleanliness and saving time.

  • Efficiently cleans all surfaces in the room

  • Can reach tight spaces and corners easily

  • Saves time and effort for the user

  • Examples: Roomba vacuum cleaner, iRobot Braava mopping robot

Add your answer

Q327. Auotmate checkbox scenario using Selenium with Java?

Ans.

Automate checkbox scenario using Selenium with Java

  • Identify the checkbox element using appropriate locators (id, name, xpath, etc.)

  • Use Selenium WebDriver to interact with the checkbox element

  • Use the 'isSelected()' method to check if the checkbox is already selected or not

  • Use the 'click()' method to select or deselect the checkbox

Add your answer

Q328. Explain how CLR works

Ans.

CLR is the runtime environment for .NET applications that manages memory, security, and execution of code.

  • CLR stands for Common Language Runtime

  • It compiles code into an intermediate language (IL) that can run on any platform with CLR installed

  • CLR manages memory through garbage collection

  • It provides security through code access security (CAS)

  • CLR also includes just-in-time (JIT) compilation for improved performance

Add your answer

Q329. What are JAR files?

Ans.

JAR files are Java Archive files that store multiple Java class files and related metadata.

  • JAR files are used to package Java classes, resources, and metadata into a single file.

  • They are commonly used for distributing Java libraries or applications.

  • JAR files can be created using the 'jar' command in Java.

  • They can also be executed using the 'java -jar' command.

  • Example: mylibrary.jar contains all the class files and resources needed for a Java library.

Add your answer

Q330. please write a code for pulling non alphabetic data from a string

Ans.

Code to extract non-alphabetic characters from a string

  • Iterate through each character in the string

  • Check if the character is not in the range of 'A' to 'Z' and 'a' to 'z'

  • Add the non-alphabetic character to a separate array of strings

Add your answer

Q331. Explain interfaces in Java

Ans.

Interfaces in Java define a contract for classes to implement certain methods.

  • Interfaces are like a blueprint for classes to follow

  • They can contain method signatures but no implementation

  • Classes can implement multiple interfaces

  • Interfaces can extend other interfaces

  • Example: Comparable interface for sorting objects

Add your answer

Q332. fetch the data for state and city based n country selection

Add your answer

Q333. Maximum length of subarray of given sum

Ans.

Find the maximum length of a subarray with a given sum in an array.

  • Use a hashmap to store the running sum and its corresponding index.

  • Iterate through the array and update the hashmap with the running sum.

  • Check if the difference between the current sum and the target sum exists in the hashmap to find the subarray length.

Add your answer

Q334. Micro service architecture: Handling service down-time

Ans.

Handling service downtime in microservice architecture is crucial for maintaining system reliability.

  • Implement circuit breakers to prevent cascading failures

  • Use service discovery to automatically route traffic to healthy instances

  • Implement retry mechanisms with exponential backoff to handle transient failures

  • Monitor service health and performance metrics to proactively detect issues

  • Implement graceful degradation to provide basic functionality when a service is down

Add your answer

Q335. Micro service architecture: Handling too many requests

Ans.

Implement rate limiting, load balancing, and circuit breaking to handle too many requests in micro service architecture.

  • Implement rate limiting to control the number of requests a service can handle within a specific time frame.

  • Use load balancing to distribute incoming requests evenly across multiple instances of a service.

  • Implement circuit breaking to prevent cascading failures and overload in case of high traffic.

  • Consider using caching mechanisms to store frequently accesse...read more

Add your answer

Q336. explain Integration BPM human task with SOA

Ans.

Integration of BPM human task with SOA involves connecting business processes with service-oriented architecture.

  • BPM human task defines the steps and actions required for a specific task in a business process.

  • SOA is an architectural style that enables the creation of loosely coupled, reusable services.

  • Integration involves connecting the human tasks defined in BPM with the services in SOA to automate and streamline business processes.

  • This integration allows for better coordina...read more

Add your answer

Q337. FInd the range of available IP addres based in the input IP and subnet

Ans.

Calculate the range of available IP addresses based on input IP and subnet.

  • Determine the network address and broadcast address using the input IP and subnet mask.

  • Calculate the range of available IP addresses between the network address and broadcast address.

  • Exclude the network address and broadcast address from the range of available IP addresses.

Add your answer

Q338. Rotate k elements to the right in an array

Ans.

Rotate k elements to the right in an array

  • Create a new array with the same length as the original array

  • Copy elements from the original array to the new array starting from index (k % array length)

  • Copy remaining elements from the original array to the new array

  • Return the new array as the rotated array

Add your answer

Q339. Longest Palindromic Substring in a given String

Ans.

Find the longest palindromic substring in a given string.

  • Use dynamic programming to check if substrings are palindromes.

  • Start with single characters as potential palindromes and expand outwards.

  • Keep track of the longest palindrome found so far.

Add your answer

Q340. how do you preprocess large/small dataset

Ans.

Preprocessing large/small datasets involves cleaning, transforming, and organizing data to prepare it for analysis.

  • Remove duplicates and missing values

  • Normalize or standardize numerical features

  • Encode categorical variables

  • Feature scaling

  • Handling outliers

  • Dimensionality reduction techniques like PCA

  • Splitting data into training and testing sets

Add your answer

Q341. How would you solve this bug

Ans.

To solve the bug, I would first identify the root cause by analyzing the code, testing different scenarios, and debugging.

  • Review the code where the bug is occurring to understand the logic and flow

  • Use debugging tools to step through the code and track the variables

  • Test different scenarios to reproduce the bug and identify patterns

  • Check for any recent changes or updates that may have introduced the bug

Add your answer

Q342. Xpath and css for web elements

Ans.

Xpath and CSS are used to locate web elements on a webpage.

  • Xpath is a language used to navigate through the XML structure of a webpage.

  • CSS selectors are used to target specific HTML elements on a webpage.

  • Xpath can be used to locate elements based on their attributes, text content, or position on the page.

  • CSS selectors can be used to locate elements based on their tag name, class, ID, or attributes.

  • Both Xpath and CSS can be used in automated testing frameworks like Selenium to...read more

Add your answer

Q343. How to improve performance of a database or SQL

Ans.

To improve performance of a database or SQL, optimize queries, use indexes, normalize data, and consider hardware upgrades.

  • Optimize queries by using proper indexing and avoiding unnecessary joins

  • Normalize data to reduce redundancy and improve data integrity

  • Consider hardware upgrades such as increasing RAM or using solid-state drives

  • Monitor and analyze query performance using tools like SQL Profiler or EXPLAIN

Add your answer

Q344. Traversing singly linked list

Ans.

Traversing a singly linked list involves iterating through each node starting from the head node.

  • Start at the head node

  • Iterate through each node by following the 'next' pointer

  • Stop when reaching the end of the list (next pointer is null)

Add your answer

Q345. Merge two sorted LinkedList into a Sorted LinkedList.

Ans.

Merge two sorted LinkedList into a Sorted LinkedList.

  • Create a new LinkedList to store the merged result.

  • Iterate through both input LinkedLists and compare values to insert into the new LinkedList.

  • Handle cases where one LinkedList is longer than the other.

  • Time complexity should be O(m+n) where m and n are the lengths of the input LinkedLists.

Add your answer

Q346. Longest string with no repeating character

Ans.

Find the longest string in an array with no repeating characters.

  • Iterate through each string in the array

  • Use a set to keep track of characters seen so far

  • Update the longest string found without repeating characters

Add your answer

Q347. what do you know about oracle cloud

Ans.

Oracle Cloud is a suite of cloud computing services offered by Oracle Corporation.

  • Oracle Cloud offers a wide range of services including computing, storage, databases, analytics, and more.

  • It provides a platform for businesses to build, deploy, and manage applications in the cloud.

  • Oracle Cloud includes services such as Oracle Cloud Infrastructure (OCI), Oracle Autonomous Database, and Oracle Cloud Applications.

  • It offers high performance, scalability, and security for businesse...read more

Add your answer

Q348. Design a REST API for UserManagement system

Ans.

Design a REST API for UserManagement system

  • Use HTTP methods like GET, POST, PUT, DELETE for CRUD operations

  • Use authentication and authorization for secure access

  • Use pagination for large datasets

  • Use query parameters for filtering, sorting, and searching

  • Use response codes to indicate success or failure

  • Use versioning to manage changes in API

  • Example endpoints: /users, /users/{id}, /users/{id}/roles

Add your answer

Q349. what are 12 factors of cloud native application ?

Add your answer

Q350. can you write xpath for gear icon in edge

Ans.

Yes, the xpath for the gear icon in Edge can be written using the class name or other unique identifiers.

  • Use the class name or other unique identifiers to locate the gear icon in Edge

  • Example: //button[@class='gear-icon']

Add your answer

Q351. Explain about the design process!?

Ans.

The design process involves understanding user needs, ideation, prototyping, testing, and iterating to create user-centered solutions.

  • Research and understand user needs and goals

  • Ideate and brainstorm potential solutions

  • Create prototypes to visualize and test ideas

  • Gather feedback from users through testing

  • Iterate on designs based on feedback

  • Collaborate with stakeholders throughout the process

Add your answer

Q352. How do you explain a C student to use Java

Ans.

Explain the basics of Java in a simple and practical way, focusing on hands-on examples and real-world applications.

  • Start by explaining the basic syntax and structure of Java code

  • Use simple examples to demonstrate concepts like variables, loops, and functions

  • Show how Java is used in real-world applications, such as building websites or mobile apps

Add your answer

Q353. Write code to create a deadlock

Ans.

Creating a deadlock involves two or more threads waiting for each other to release a resource they need.

  • Create two threads, each trying to lock two resources in a different order

  • Ensure that one thread locks resource A first and then tries to lock resource B, while the other thread locks resource B first and then tries to lock resource A

  • This will result in a situation where each thread is waiting for the other to release the resource it needs, causing a deadlock

Add your answer

Q354. Write code to implement LRU Cache

Ans.

Implement LRU Cache using a data structure like LinkedHashMap in Java

  • Use LinkedHashMap to maintain insertion order

  • Override removeEldestEntry method to limit cache size

  • Update the access order on get and put operations

Add your answer

Q355. Why Oracle? What are its values

Ans.

Oracle is a leading technology company known for its innovation, reliability, and commitment to customer success.

  • Oracle is a global leader in database software, cloud solutions, and enterprise technology.

  • The company values innovation, integrity, diversity, and teamwork.

  • Oracle is committed to helping customers succeed by providing cutting-edge technology solutions.

  • Oracle's values include customer focus, excellence, and accountability.

Add your answer

Q356. Options to enhance the performance of the Integration

Ans.

To enhance integration performance, consider optimizing data flow, reducing network latency, and implementing caching.

  • Optimize data flow by reducing unnecessary data transfers and minimizing data transformation.

  • Reduce network latency by using a content delivery network (CDN) or implementing a local cache.

  • Implement caching to reduce the number of requests to external systems and improve response times.

  • Consider using asynchronous processing to improve overall system performance...read more

Add your answer

Q357. Product of an array except self

Ans.

Calculate the product of all elements in an array except for the element itself.

  • Iterate through the array and calculate the product of all elements except the current element.

  • Use two separate arrays to store the product of elements to the left and right of the current element.

  • Multiply the corresponding elements from the left and right arrays to get the final result.

Add your answer

Q358. Types or ratio? How it helps in analysis

Ans.

Financial ratios help in analyzing a company's financial performance and health.

  • Types of ratios include liquidity ratios, profitability ratios, leverage ratios, and efficiency ratios.

  • Liquidity ratios measure a company's ability to meet short-term obligations (ex: current ratio)

  • Profitability ratios assess a company's ability to generate profits (ex: return on equity)

  • Leverage ratios indicate the level of debt a company has taken on (ex: debt-to-equity ratio)

  • Efficiency ratios me...read more

Add your answer

Q359. Linux bash script to rename files

Ans.

Use 'mv' command in a bash script to rename files in Linux.

  • Use 'mv' command followed by the current file name and the new file name to rename files.

  • You can use wildcards like '*' to rename multiple files at once.

  • Make sure to test the script on a few files before running it on all files.

Add your answer

Q360. Linux system calls with an example

Ans.

Linux system calls are functions provided by the kernel for user-space programs to interact with the operating system.

  • System calls are used to request services from the kernel, such as creating processes, opening files, and networking.

  • Examples of system calls include open(), read(), write(), fork(), exec(), and socket().

  • System calls are invoked using a software interrupt or trap instruction, switching the CPU from user mode to kernel mode.

  • System calls are essential for the fu...read more

Add your answer

Q361. Difference between == and equals

Ans.

The '==' operator is used for comparing values of primitive data types, while the 'equals' method is used for comparing objects in Java.

  • Use '==' to compare primitive data types like int, char, boolean, etc.

  • Use 'equals' method to compare objects like Strings, Lists, etc.

  • Example: int a = 5; int b = 5; if(a == b) { // true }

  • Example: String str1 = 'hello'; String str2 = 'hello'; if(str1.equals(str2)) { // true }

Add your answer

Q362. Merge sort. Explain and implement.

Ans.

Merge sort is a divide and conquer algorithm that divides the input array into two halves, sorts each half, and then merges the sorted halves.

  • Divide the array into two halves

  • Recursively sort each half

  • Merge the sorted halves back together

Add your answer

Q363. what is normalization ?

Add your answer

Q364. What is data shuffling in spark

Ans.

Data shuffling in Spark is the process of redistributing data across partitions to optimize parallel processing.

  • Data shuffling occurs when data needs to be moved across partitions, typically during operations like groupBy, join, or sortBy.

  • It involves transferring data between executors, which can be a costly operation in terms of performance.

  • Data shuffling can impact the performance of a Spark job, so it's important to minimize unnecessary shuffling.

  • One way to reduce data shu...read more

Add your answer

Q365. Triggers and it's types and importance.

Ans.

Triggers are database objects that are used to automatically execute a set of actions when a specific event occurs.

  • Triggers can be of two types: DML triggers and DDL triggers.

  • DML triggers are fired in response to DML (Data Manipulation Language) events like INSERT, UPDATE, and DELETE.

  • DDL triggers are fired in response to DDL (Data Definition Language) events like CREATE, ALTER, and DROP.

  • Triggers are important as they help in maintaining data integrity, enforcing business rule...read more

Add your answer

Q366. Opera cloud itil. How to handle support

Ans.

To handle support for Opera cloud ITIL, follow ITIL best practices and prioritize incidents based on impact and urgency.

  • Follow ITIL best practices for incident management

  • Prioritize incidents based on impact and urgency

  • Ensure timely resolution and communication with stakeholders

  • Maintain documentation and knowledge base for future reference

  • Continuously improve support processes through feedback and analysis

Add your answer

Q367. Explain heap sort

Ans.

Heap sort is a comparison-based sorting algorithm that uses a binary heap data structure.

  • It divides the input into a sorted and an unsorted region.

  • It repeatedly extracts the largest element from the unsorted region and inserts it into the sorted region.

  • It has a worst-case and average-case time complexity of O(n log n).

Add your answer

Q368. Differentiate between mutex and semaphores

Ans.

Mutex and semaphores are synchronization mechanisms used in multi-threaded environments.

  • Mutex is used to provide mutual exclusion, allowing only one thread to access a shared resource at a time.

  • Semaphore is used to control access to a shared resource by multiple threads, allowing a specified number of threads to access it simultaneously.

  • Mutex is binary, meaning it has only two states: locked or unlocked.

  • Semaphore can have a count greater than one, indicating the number of thr...read more

Add your answer

Q369. Explain internal working of HashMap,Stream operations

Ans.

HashMap is a key-value data structure. Stream operations are used for processing collections of objects.

  • HashMap uses hashing to store and retrieve key-value pairs. It has constant time complexity for basic operations like get and put.

  • Stream operations are used for filtering, mapping, and reducing collections of objects. They are lazy and can be parallelized for better performance.

  • Examples of stream operations include filter(), map(), reduce(), and forEach().

Add your answer

Q370. How do access elements in XML/JSON data

Ans.

To access elements in XML/JSON data, use appropriate methods like XPath for XML and dot notation for JSON.

  • For XML data, use XPath expressions to navigate and extract specific elements or attributes.

  • For JSON data, use dot notation to access nested objects or arrays.

  • In PL/SQL, you can use XMLTable or JSON_TABLE functions to extract data from XML or JSON respectively.

Add your answer

Q371. function to reverse a linked list

Ans.

Function to reverse a linked list

  • Create three pointers: prev, current, next

  • Iterate through the linked list, updating pointers accordingly

  • Set the next of current to prev, move prev and current pointers forward

  • Return the new head of the reversed linked list

Add your answer

Q372. function to detect loop in a linked list

Ans.

Use Floyd's Tortoise and Hare algorithm to detect loop 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 loop in the linked list.

Add your answer

Q373. Write selenium code for getting values in a dynamic table

Ans.

Use Selenium to extract values from a dynamic table

  • Identify the table using its locator (id, class, xpath, etc.)

  • Iterate through the rows and columns of the table to extract values

  • Use Selenium commands like findElements and getText to retrieve the values

  • Handle dynamic content by waiting for elements to be present or visible

Add your answer

Q374. how do we measure code quality?

Ans.

Code quality can be measured through various metrics and tools to ensure readability, maintainability, efficiency, and reliability.

  • Use code review processes to assess adherence to coding standards and best practices

  • Utilize static code analysis tools to identify potential bugs, code smells, and security vulnerabilities

  • Measure code complexity using metrics like cyclomatic complexity and maintainability index

  • Track code coverage with unit tests to ensure adequate test coverage

  • Mon...read more

Add your answer

Q375. how many threads can be run on n-cores?

Ans.

The number of threads that can be run on n-cores depends on the specific hardware and software configurations.

  • The number of threads that can be run on n-cores is influenced by factors such as the type of processor, operating system, and workload.

  • In general, the number of threads that can be run on n-cores is limited by the number of physical and logical cores available.

  • For example, a quad-core processor with hyper-threading support can run up to 8 threads simultaneously.

Add your answer

Q376. Print first non-repeating character in the given string.

Ans.

Print the first non-repeating character in a given string.

  • Create a hash table to store the frequency of each character in the string.

  • Iterate through the string and update the frequency of each character in the hash table.

  • Iterate through the string again and return the first character with a frequency of 1.

Add your answer

Q377. Permutation of the number without duplicates

Ans.

Generate all permutations of a given number without duplicates

  • Use backtracking to generate all possible permutations

  • Avoid duplicates by keeping track of used digits

  • Recursively swap digits to generate permutations

Add your answer
Q378. Design a WhatsApp chat system.
Ans.

Design a WhatsApp chat system for real-time messaging.

  • Use WebSocket for real-time communication

  • Implement end-to-end encryption for security

  • Allow users to send text, images, videos, and documents

  • Include features like group chats, read receipts, and message forwarding

Add your answer

Q379. Delete nth node from end of linked list

Ans.

Delete nth node from end of linked list

  • Use two pointers, one to traverse the list and another to keep track of the nth node from the end

  • Once the nth node is reached, move both pointers until the end of the list

  • Delete the node pointed by the second pointer

Add your answer

Q380. Unbilled and unearned revenue, it's differences

Ans.

Unbilled revenue is revenue that has been earned but not yet invoiced, while unearned revenue is payment received for goods or services not yet delivered.

  • Unbilled revenue is recognized as accounts receivable on the balance sheet, while unearned revenue is recognized as a liability.

  • Unbilled revenue represents work that has been completed but not yet billed to the customer, while unearned revenue represents advance payments for goods or services.

  • Examples of unbilled revenue inc...read more

Add your answer

Q381. Accrual and provisions and difference between them

Ans.

Accruals are expenses incurred but not yet paid, while provisions are liabilities that are uncertain in timing or amount.

  • Accruals are recognized when expenses are incurred but not yet paid, while provisions are recognized when there is a probable obligation that can be estimated.

  • Accruals are based on past events and are more certain, while provisions are based on future events and are less certain.

  • Examples of accruals include salaries payable and interest payable, while examp...read more

Add your answer

Q382. Reverse a string

Ans.

Reverse a string

  • Use a loop to iterate through the string and append each character to a new string in reverse order

  • Alternatively, use the built-in reverse() method for strings in some programming languages

Add your answer

Q383. I was asked to find diameter of a binary Tree

Ans.

To find the diameter of a binary tree, we need to find the longest path between any two nodes in the tree.

  • Traverse the tree recursively and calculate the height of the left and right subtrees.

  • Calculate the diameter of the left and right subtrees recursively.

  • The diameter of the tree is the maximum of the following three values: 1. Diameter of the left subtree 2. Diameter of the right subtree 3. Height of the left subtree + height of the right subtree + 1

  • Example: 1 / \ 2 3 / \ ...read more

Add your answer

Q384. How dependency injection works?

Ans.

Dependency injection is a design pattern where components are given their dependencies rather than creating them internally.

  • Dependencies are injected into a component through constructor injection, setter injection, or interface injection.

  • This allows for easier testing, flexibility, and reusability of components.

  • Common frameworks for dependency injection include Spring Framework for Java and Angular for TypeScript.

  • Example: In Spring Framework, dependencies are defined in a co...read more

Add your answer

Q385. HLD design for microservices base problem.

Ans.

HLD design for microservices involves breaking down a monolithic application into smaller, independent services.

  • Identify the business capabilities and break them down into microservices

  • Design the communication protocol between the microservices

  • Ensure fault tolerance and scalability

  • Use containerization and orchestration tools like Docker and Kubernetes

  • Consider security and data management

  • Example: Breaking down an e-commerce application into microservices for product catalog, s...read more

Add your answer

Q386. SQL query for minimum salary of employees

Ans.

SQL query to find minimum salary of employees

  • Use the SELECT statement to retrieve the minimum salary

  • Use the MIN() function to find the minimum value

  • Specify the column name for the salary field

  • Specify the table name where the salary field is located

Add your answer

Q387. How do you create thread locks

Ans.

Thread locks are created using synchronization mechanisms to prevent multiple threads from accessing shared resources simultaneously.

  • Use synchronized keyword in Java to create a synchronized block or method

  • Use locks from java.util.concurrent.locks package like ReentrantLock

  • Use synchronized collections like ConcurrentHashMap to handle thread safety

  • Implement thread-safe data structures like BlockingQueue for producer-consumer scenarios

Add your answer

Q388. Consumer producer multithreading program.

Ans.

Consumer producer multithreading program involves multiple threads sharing a common buffer to produce and consume data.

  • Use synchronized data structures like BlockingQueue to handle thread synchronization.

  • Implement separate producer and consumer classes with run methods.

  • Use wait() and notify() methods to control the flow of data between producer and consumer threads.

Add your answer

Q389. What is web service flow

Ans.

Web service flow is the sequence of steps involved in the communication between a client and a server over the internet.

  • Web service flow involves a client sending a request to a server

  • The server processes the request and sends a response back to the client

  • The response can be in various formats such as XML, JSON, or plain text

  • Web service flow can be synchronous or asynchronous

  • Examples of web services include RESTful APIs and SOAP web services

Add your answer

Q390. Advantage disadvantage of monolith and microservices

Ans.

Monolith has simplicity but lacks scalability, while microservices offer flexibility but introduce complexity.

  • Monolith: Simplicity in development and deployment, easier to debug and test

  • Monolith: Lack of scalability, all components tightly coupled

  • Microservices: Flexibility to use different technologies for different services

  • Microservices: Scalability, each service can be independently scaled

  • Microservices: Increased complexity in managing multiple services and communication be...read more

Add your answer

Q391. How was the server working in the hotels

Ans.

The server in hotels was working efficiently and reliably.

  • The server was able to handle high traffic and data volume without any major issues.

  • Regular maintenance and updates were performed to ensure optimal performance.

  • The server was also equipped with backup and disaster recovery systems to prevent any data loss or downtime.

  • Examples of applications running on the server include reservation systems, billing systems, and guest management systems.

Add your answer

Q392. Explain wait() and signal()

Ans.

wait() and signal() are functions used for synchronization in multithreading.

  • wait() is used to make a thread wait until a certain condition is met

  • signal() is used to wake up a waiting thread when the condition is met

  • Example: Producer-consumer problem where producer signals consumer to consume when a new item is produced

Add your answer

Q393. Explain REST with examples

Ans.

REST is an architectural style for designing networked applications

  • REST stands for Representational State Transfer

  • It uses standard HTTP methods like GET, POST, PUT, DELETE

  • Resources are identified by URIs

  • Data is transferred in JSON or XML format

  • Example: GET request to 'https://api.example.com/users' to retrieve a list of users

Add your answer

Q394. Singleton Class example

Ans.

A Singleton class is a class that can only have one instance created at a time.

  • Singleton classes are often used for managing resources that should only have one instance, such as a database connection.

  • To implement a Singleton class, you typically make the constructor private and provide a static method to access the single instance.

  • Example: Singleton class for logging system where only one instance of the logger is needed.

Add your answer

Q395. CAP Theorem and its trade-offs

Ans.

CAP Theorem states that in a distributed system, it is impossible to simultaneously guarantee consistency, availability, and partition tolerance.

  • Consistency: All nodes in the system have the same data at the same time.

  • Availability: Every request gets a response, even if some nodes are down.

  • Partition Tolerance: The system continues to operate despite network partitions.

  • Trade-offs: In a distributed system, you can only have two out of the three - Consistency, Availability, and ...read more

Add your answer

Q396. diferent type of exceptions you handled and explain

Ans.

Handled exceptions like NullPointerException, ArrayIndexOutOfBoundsException, IOException, etc.

  • NullPointerException: Occurs when trying to access a method or property of a null object.

  • ArrayIndexOutOfBoundsException: Occurs when trying to access an index outside the bounds of an array.

  • IOException: Occurs when there is an issue with input/output operations.

Add your answer

Q397. What is dynamic programming?

Ans.

Dynamic programming is a technique to solve complex problems by breaking them down into smaller subproblems.

  • It involves solving subproblems only once and storing their solutions for future use.

  • It is used in optimization problems, such as finding the shortest path or maximizing profit.

  • Examples include the knapsack problem and the Fibonacci sequence.

  • It can be implemented using either a top-down or bottom-up approach.

  • Dynamic programming requires both optimal substructure and ove...read more

Add your answer

Q398. What is SQL ? What are the market trend

Ans.

SQL is a programming language used for managing and manipulating relational databases.

  • SQL stands for Structured Query Language.

  • It is used to communicate with and manipulate databases.

  • SQL can be used to create, modify, and retrieve data from databases.

  • It is widely used in data analysis and data management roles.

  • Some popular relational database management systems that use SQL include MySQL, Oracle, and SQL Server.

Add your answer

Q399. What is your background in Risk?

Ans.

I have a strong background in Risk with a focus on financial analysis and modeling.

  • Completed coursework in risk management and financial analysis

  • Worked as a risk analyst at XYZ company for 3 years

  • Developed risk models to assess credit and market risk

  • Conducted stress testing and scenario analysis to evaluate potential risks

  • Regularly monitored and reported on key risk indicators

Add your answer

Q400. Use case study implementation in SOA and osb

Ans.

SOA and OSB implementation in use case study

  • Identify business requirements and goals for the use case study

  • Design service-oriented architecture (SOA) to meet the requirements

  • Implement Oracle Service Bus (OSB) for communication between services

  • Test and validate the implementation to ensure functionality and performance

  • Document the use case study implementation for future reference

Add your answer
1
2
3
4
5
6
7

More about working at Oracle

#22 Best Mega Company - 2022
#3 Best Internet/Product Company - 2022
Contribute & help others!
Write a review
Share interview
Contribute salary
Add office photos

Interview Process at GAVS Technologies

based on 623 interviews
Interview experience
4.1
Good
View more
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Top Interview Questions from Similar Companies

3.5
 • 1.8k Interview Questions
4.0
 • 1.2k Interview Questions
4.1
 • 221 Interview Questions
3.6
 • 184 Interview Questions
3.6
 • 182 Interview Questions
3.7
 • 139 Interview Questions
View all
Top Oracle Interview Questions And Answers
Share an Interview
Stay ahead in your career. Get AmbitionBox app
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
75 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter