4 ms·
Basically, interview questions at such companies test your knowledge of basic algorithms and data structures. If you have problem with answering such questions,
by solomatov 11y ago
Basically, interview questions at such companies test your knowledge of basic algorithms and data structures. If you have problem with answering such questions, I recommend you taking a couple of courses in these fields on Coursera or read basic algorithm books (and of course solve exercises).
I interview people a lot, and I always ask such questions. I just don't want to have people who don't know how data structures they work with every day work and which time complexity they have. You would be surprised, to see how many people don't know the basics.
Often companies, like google, and facebook ask brain teaser, i.e. tricky questions with tricky answers. I agree with you that such questions are mostly useless and make people feel stupid, especially if they didn't have experience with them.
P.S. It would be nice if you provide examples of tasks which you against, so that everybody who reads this is on the same page.