At my company, I would approach the interview in close the the same way as we do the interviews for interns from the local university... which is to say, we ask a lot of questions looking to find out what they actually know about the language.
We would ask for things like definitions of the following terms (the last two we wouldn't usually expect junior programmers to know; bonus points if you do):
- static
- const
- protected
- friend
- virtual
- mutable
- explicit
- volatile
We would also ask about some programming concepts:
- What is a memory leak?
- What is a mutex?
- What is a deadlock (and how might you prevent one)?
We would ask at least one general programming competence questions:
- In the language of your choice, write a short program that outputs odd numbers between 0 and 100.
We would ask some C or C++-specific questions:
- In C++, write an assignment operator for a String class.
- In C or C++, write an infinite loop construct.
- In C, write a MIN #define that takes two arguments and returns the smaller.
- in C++, write a min function that takes two arguments and returns the smaller.
We might also ask some other thinking-type questions:
- For the function
int* sort( int* data, int size );
what are some inputs you would give it to determine if it works correctly?
- If you are designing a card game for (random card game, like poker), what sort of data structures might you use. How would they interact?
We might also ask some trickier questions, based on how well the interview goes, but we wouldn't expect a junior programmer to answer them. Depending on the question, they might be expected to provide an indication of how they would research it. For interns, we are looking for at least a little understanding of the terms and concepts, and stronger answers on the other questions. For a junior developer, if they listed C or C++ experience, we would expect most of the keywords to be answerable, as well as most of the other questions I mentioned. For a more experienced developer, we'd expect nearly all of the questions to be answered, and we would likely press them for more than just the surface answers (such as "Can you think of a time when declaring a variable both const and volatile might be useful?")