Oracle
10+ Ellenbarrie Industrial Gases Interview Questions and Answers
Q1. Modified Balanced Parentheses where a character can be matched with any other character, i.e. / with &, ! with ? and so on.
Modified Balanced Parentheses where characters can be matched with any other character.
Use a stack to keep track of opening characters
When encountering a closing character, check if it matches the top of the stack
If it matches, pop from the stack, else return false
Continue until end of string, return true if stack is empty
Q2. Given an array of strings, print all the possible combinations of strings created by picking one character from each string of the array. The individual strings do not contain any duplicates. Ex: {ABC, DE} Ans ...
read morePrint all possible combinations of strings by picking one character from each string in the array.
Iterate through each character of the first string and combine it with each character of the second string.
Repeat the process for all strings in the array to get all possible combinations.
Use nested loops to generate combinations efficiently.
Q3. Subset sum variant, find missing number using single loop, difference between two dates, , Core Java concept , Sql, finding duplicate number in list, finding loop in linkedlist, finding node where cycle starts ...
read moreInterview questions for Application Engineer role covering various topics.
Subset sum variant - finding a subset of numbers that add up to a given sum
Single loop missing number - finding a missing number in an array using a single loop
Difference between two dates - calculating the difference between two dates in Java
Core Java concepts - knowledge of basic Java concepts such as inheritance, polymorphism, etc.
SQL - knowledge of SQL queries and database management
Finding duplicat...read more
Q4. Given a date in string format, write a java program to return the date n days after the given date. Solve the question without using DateTimeFormatter or any similar Date parsing libraries.
Java program to calculate date n days after given date without using Date parsing libraries.
Parse the input date string to extract day, month, and year components.
Calculate the total number of days represented by the input date.
Add the specified number of days to the total days calculated.
Convert the final total days back to day, month, and year components to get the new date.
Q5. Print all combinations of numbers in an array which sum up to a number k. Ex : Arr={3,1,4,5} k=5 Ans : {{1,4},{5}}
Use backtracking to find all combinations of numbers in an array that sum up to a given number.
Start by sorting the array in non-decreasing order to easily identify combinations.
Use backtracking to recursively find all combinations that sum up to the target number.
Keep track of the current combination and the remaining sum as you traverse the array.
Add the current combination to the result when the sum equals the target number.
Q6. Print all Pythagorean triplets within a given range.
Print Pythagorean triplets within a given range.
Iterate through all possible combinations of a, b, and c within the given range
Check if a^2 + b^2 = c^2 for each combination
Print the triplets that satisfy the Pythagorean theorem
Q7. Check if given string has Balanced Parentheses.
Check if a string has balanced parentheses.
Use a stack to keep track of opening parentheses.
Iterate through the string and push opening parentheses onto the stack.
When a closing parenthesis is encountered, pop from the stack and check if it matches the closing parenthesis.
If stack is empty at the end and all parentheses are matched, the string has balanced parentheses.
Q8. Find missing and repeating numbers in a group of billions of numbers without extra space.
Find missing and repeating numbers in a group of billions of numbers without extra space.
Use bitwise XOR to find the missing number
Use modulo and division to find the repeating number
Divide the numbers into smaller chunks to avoid memory overflow
Q9. Find the sq root for a number upto 2 decimal places
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().
Q10. Find the longest path in a binary tree. (Leaf to Leaf)
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
Q11. Check two binary trees identical or not
Check if two binary trees are identical or not.
Traverse both trees simultaneously and compare each node
If any node is different, return false
If both trees are traversed completely and all nodes are same, return true
Q12. design the url shortner
Design a URL shortener service
Generate a unique short code for each long URL
Store the mapping of short code to long URL in a database
Redirect users from short URL to long URL when accessed
Consider implementing custom short domains for branding
Track analytics for shortened URLs for performance monitoring
Q13. Multiply to strings
To multiply two strings, convert them to integers, multiply them, and convert the result back to a string.
Convert the strings to integers using parseInt()
Multiply the integers together
Convert the result back to a string using toString()
More about working at Oracle
Top HR Questions asked in Ellenbarrie Industrial Gases
Interview Process at Ellenbarrie Industrial Gases
Top Applications Engineer Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month