Algorithm Engineer Interview Questions

793 algorithm engineer interview questions shared by candidates

You have three sock drawers. One has red and blue socks, one has blue and green socks, and one has green and red socks. What is the expected number of socks you must pull to be sure which drawer is which, assuming that the number of socks of each color in each drawer is both large and equal?
avatar

Algorithm Developer

Interviewed at Hudson River Trading

4.1
Sep 27, 2024

You have three sock drawers. One has red and blue socks, one has blue and green socks, and one has green and red socks. What is the expected number of socks you must pull to be sure which drawer is which, assuming that the number of socks of each color in each drawer is both large and equal?

Pretty much the same thing as the Microsoft one in this link. I wasted too much time on question 2 and didn't get a chance to submit an answer but I finished it for fun after the test. https://webcache.googleusercontent.com/search?q=cache:KocTw550s_UJ:https://leetcode.com/discuss/interview-question/760379/Microsoft-or-OA-2020-or-Word-Machine+&cd=1&hl=en&ct=clnk&gl=ru&client=safari
avatar

Algorithm Engineer

Interviewed at Hudson River Trading

4.1
Jan 6, 2021

Pretty much the same thing as the Microsoft one in this link. I wasted too much time on question 2 and didn't get a chance to submit an answer but I finished it for fun after the test. https://webcache.googleusercontent.com/search?q=cache:KocTw550s_UJ:https://leetcode.com/discuss/interview-question/760379/Microsoft-or-OA-2020-or-Word-Machine+&cd=1&hl=en&ct=clnk&gl=ru&client=safari

phone interview: (1) 3x3 large square, the surface is painted in red. After cutting into 27 pieces, just take one piece and throw it on the table. Five sides are white and white. Ask the probability that the last face is red. (2) X = the sum of 100 rolls of dice, Y = the number of heads of 600 coin flips, ask Pr (X>Y) (3) N points randomly in a circle. The probability that all of them lie in a semicircle
avatar

Algorithm Developer

Interviewed at Hudson River Trading

4.1
Jan 16, 2022

phone interview: (1) 3x3 large square, the surface is painted in red. After cutting into 27 pieces, just take one piece and throw it on the table. Five sides are white and white. Ask the probability that the last face is red. (2) X = the sum of 100 rolls of dice, Y = the number of heads of 600 coin flips, ask Pr (X>Y) (3) N points randomly in a circle. The probability that all of them lie in a semicircle

Spaghetti in a bowl question. (Pick up one end of a spaghetti and you can either join it to the other end of the spaghetti you are holding which created a loop or you can pick any other end in the bowl and join it to that. Find the expected number of loops.) Another spaghetti question (I think the interviewer loved spaghetti): You have a plate of spaghetti in front of you (no sauce!). You pick two ends and tie them together. Then you pick two more ends and tie them together. Continue until there are no free ends left. If there were n spaghettis originally, what is the probability that you now have a single giant loop consisting of all the spaghettis?
avatar

Algorithm Developer

Interviewed at Hudson River Trading

4.1
Oct 23, 2016

Spaghetti in a bowl question. (Pick up one end of a spaghetti and you can either join it to the other end of the spaghetti you are holding which created a loop or you can pick any other end in the bowl and join it to that. Find the expected number of loops.) Another spaghetti question (I think the interviewer loved spaghetti): You have a plate of spaghetti in front of you (no sauce!). You pick two ends and tie them together. Then you pick two more ends and tie them together. Continue until there are no free ends left. If there were n spaghettis originally, what is the probability that you now have a single giant loop consisting of all the spaghettis?

Viewing 1 - 10 interview questions

Glassdoor has 793 interview questions and reports from Algorithm engineer interviews. Prepare for your interview. Get hired. Love your job.