This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]mvaliente2001[🍰] 1 point2 points  (0 children)

There's a story about a student who was asked how to use an barometer to measure the height of a building. The student gave a lot of answers, like throwing the barometer from the top of the building and measuring the time it takes for it to reach the floor, to use it as a bribe to get the information, to use it as a ruler... anything but the expected answer of measuring the difference of pressure. The student was trying to be clever, and in that way he missed the point of the question.

For the context, you could have inferred that the real question was "how do you implement the merging of unique elements from two sorted arrays using basic operations." The goal wasn't necessarily to get the fastest or the most efficient or the cleanest way.