How would you write a sort routine to ensure that identical elements in the input are maximally spread in the output?
Engineer Interview Questions
935,577 engineer interview questions shared by candidates
Implement an LRU cache.
Sort a million 32 bit integers using only 2MB of RAM
What's the difference between abstract and interface in Java
Given a string, return a boolean value if the strings contains matching brackets Example: Input: "This is [a valid] string" Output: True Input: "This is an [invalid string" Output: False
How to sum all values in a range of values between A and B?
Given an array of integers, implement a class to take a snapshot. In particular 2 methods: - int takeSnaphost() //returns the snapshot id - int getFromSnapshot(int snapshotId, int arrayIndex)
Three questions; two on algorithms and one on debugging.
While explaining differences between TCP and UDP, when I mentioned that UDP is more convenient for video streaming websites as video will keep streaming even if packages get dropped. Interviewer asked me isn't that the opposite of what we want as this could hamper the video quality.
If you have a 5 gallon jug and a 3 gallon jug how do you get exactly 4 gallons?
Viewing 2301 - 2310 interview questions