C++ Tech Interviews
I’m taking all advice on gotchas and the dark occult corners of C++ as they show up in interview tech outs.
My C++ skills are solid. I’m very confident. But I also have a history of choking on tech outs, then spending days screaming at brick walls because “I knew that.”
I’m working on a nice happy pure c++ threaded and networked app to keep my chops up. Not much of a challenge. But I’m not sure it’s going to be enough.
So what’s the nastiest, gnarliest C++ question you’ve given or received in a tech out? Come on. Let’s make a list of these.
Tags: Programming
January 11th, 2012 at 10:19 am
Forget the hard stuff… Give them an opportunity to show whether or not they know how to properly use inheritance and virtual functions. Give them a design problem (I’ve used Monopoly) and see where they put the responsibility.
As for tricky questions… Here’s one you could use but it requires knowledge of the standard library and references…
Given a std::map stringToString;
If you want to find out if a key is already used, you could do this:
if(stringToString[key] …)
- Why should you not generally do this to find if something is in them map
- What should you do instead
- What feature of C++ almost requires this observation?