I've recently attended an interview for a software developer position. At one point I was given three questions - two code writing and another more theoretical. One of the code writing questions included writing a parser for arithmetic expressions string. I've came up with a working algorithm, but I didn't have time to write the code (also, there was another more efficient algorithm which the interviewer told me about later).
At home I've checked the algorithm - Shunting Yard), which is quite complicated (my algorithm was even more complicated and was similar to Operator-precedence algorithm). Is it realistic to expect an applicant to implement this argument in 20 minutes on paper without Internet access and answer two more moderately hard questions? What were the expectations?