Oracle Coding & Algorithms Interview Questions
Master your tech interview with our curated database of real questions from top companies.
Implement an LRU cache
Design and implement an in-memory cache that evicts entries using the Least Recently Used (LRU) policy. The cache should store key–value pairs and sup...
Solve three DSA problems: trie, window, intervals
1) Design and implement an autocomplete service. Support insert(word) to add a word and suggest(prefix) to return up to five existing words that start...
Minimize sum with halving operations
You are given an array of non-negative integers nums and an integer k. In one operation, choose any index i and replace nums[i] with ceil(nums[i] / 2)...
Determine if robot path is bounded
A robot starts at (0, 0) facing North on an infinite grid. It executes a string s consisting of 'G' (move forward 1 unit), 'L' (turn left 90°), and 'R...
Find shortest subarray meeting target sum
Given an integer array nums (values may be negative) and an integer T, return the length of the shortest non-empty contiguous subarray whose sum is at...