What browser would you take with you on an isolated island?
Ask HN: What is your favourite technical interview question?
11–20 of 23 posts
Re: Ask HN: What is your favourite technical interview question?
#12You are given two eggs and a hundred story building. You need to tell me, using as few drops as possible, what the highest floor you can drop an egg from and it won't break.
Re: Ask HN: What is your favourite technical interview question?
#13Re: Ask HN: What is your favourite technical interview question?
#14Not my favorite, but interesting: You are given two eggs and a hundred story building. You need to tell me, using as few drops as possible, what the highest floor you can drop an egg from and it won't break.
Re: Ask HN: What is your favourite technical interview question?
#15Re: Ask HN: What is your favourite technical interview question?
#16Not my favorite, but interesting: You are given two eggs and a hundred story building. You need to tell me, using as few drops as possible, what the highest floor you can drop an egg from and it won't break.
Is the answer you're looking for a binary search algorithm, or do you have some lateral thinking solution in mind?
Re: Ask HN: What is your favourite technical interview question?
#17Earlier quoted context omitted.
Is the answer you're looking for a binary search algorithm, or do you have some lateral thinking solution in mind?
Because you only have 2 eggs I don't think you can use a binary search algorithm (assuming I understood the question correctly). I think you'd have to start at floor 2, if that passed then jump to floor 4, etc. until you have an egg break (lets call this floor n). Then, you go to the floor below the one that broke the egg to see if an egg survives that drop. You'll then know, using only 2 eggs the highest floor you c…
Re: Ask HN: What is your favourite technical interview question?
#18I understand they are trying to get an idea that i have a very basic knowledge of programming, but, this has been a pretty good gauge on the quality of a company. "Define polymorphism."
Without fail, every single interviewer in my experience was looking for an answer strictly in terms of whatever language(s) they're using at the company, or whatever language the interviewer is most familiar with. If you stray outside of what they know and what they're looking for, they have no idea what you're talking about.
Polymorphism in Java is slightly different than for Ruby than for C than for Haskell than for yadda, yadda. No matter what, it's always going to be somewhat arbitrary and tied to some kind of language dependent implementation or feature. If your language doesn't even have classes, the answer is different, if your language doesn't have functions, it's different, etc, etc.
I suppose the closest thing to a right answer would be to define it in pure mathematical terms using Turing machine notation, so as to make it universal. However I have no idea if such an answer even exists. If anyone has seen such a thing, please do share it.
A better version I would ask would be: define polymorphism using x86 AT&T assembly. or: define what polymorphism represents
Re: Ask HN: What is your favourite technical interview question?
#19I find this is a good mix of not too trivial but not overwhelming, I don't expect people to come up with the fastest possible algorithm on the spot. If they code the naive solution, that's OK if it makes sense and they can describe the performance characteristics. Then we'll talk over the algorithm and I lead them to something better and see how the conversation develops.
Re: Ask HN: What is your favourite technical interview question?
#20Earlier quoted context omitted.
Is the answer you're looking for a binary search algorithm, or do you have some lateral thinking solution in mind?
Because you only have 2 eggs I don't think you can use a binary search algorithm (assuming I understood the question correctly). I think you'd have to start at floor 2, if that passed then jump to floor 4, etc. until you have an egg break (lets call this floor n). Then, you go to the floor below the one that broke the egg to see if an egg survives that drop. You'll then know, using only 2 eggs the highest floor you c…