Given a set of numbers -50 to 50, find all pairs that add up to a certain sum that is passed in. What's the O notation for what you just wrote? Can you make it faster? Can you find an O(n) solution? Implement the O(n) solution
Software Engineering Interview Questions
429,467 software engineering interview questions shared by candidates
Find a sequence with max sum in an array of negative and positive real numbers.
Given a list of n objects, write a function that outputs the minimum set of numbers that sum to at least K. FOLLOW UP: can you beat O(n ln n)?
A train leaves San Antonio for Huston at 60mph. Another train leaves Huston for San Antonio at 80mph. Huston and San Antonio are 300 miles apart. If a bird leaves San Antonio at 100mph, and turnes around and flies back once it reaches the Huston train, and continues to fly between the two, how far will it have flown when they collide.
Given the alphabet encoded as numbers (e.g., a=1, b=2, ..., z=26), and a sequence of numbers (e.g., "23413259802"), how many strings can be generated.
You have all of the prices for a given stock for the next year. You can buy once and sell once in that year. How do you determine when to buy and sell to maximize your profit?
Write an algorithm to determine if 2 linked lists intersect
Most of them were expected. Almost all are problem solving questions. 1. Given a BST with following property find the LCA of two given nodes. Property : All children has information about their parents but the parents do not have information about their children nodes. Constraint - no additional space can be used
Why do you want to work at The Home Depot?
How would you determine if someone has won a game of tic-tac-toe on a board of any size?
Viewing 41 - 50 interview questions