So awhile back I had a thread asking what to expect in a software engineer internship interview, and I just had it today (phone interview). It was with the director of engineering at the company I'm interviewing for. It started off with a few behavioral questions such as "What would you do in situation X", and "Describe times when you've had multiple tasks to get done, how did you manage?". Then it went into more technical questions. One of which was:
Describe the difference between an array and a linked list. Describe how they are different in memory, some pros and cons between the two, and when to use one or the other |
Another was: (This one gave me some issues)
Describe the different scoping rules. |
First off, I had to get clarification on what he was even asking. I hadn't heard the term rules applied to scoping before. But after that, I just realized he was asking to describe global vs local scope and the varying degrees. That part was easy, but then he asked to describe situations where you'd use one over the other. I was stumped because I had no idea when and where to use global scope. Being stumped, I just threw out "When there are threads accessing the same data?" and then I just stated that global scope seems to be frowned upon.
Another one that was weird involved OOP.
Suppose there are two classes, car and color. Car has multiple properties, one of which is color. Color is just a class that describes a color. Why would you keep color a separate class? |
I wasn't sure on this, and kind of thought it was a trick because when I said that I wouldn't make a color class in this situation and just have an enumeration member in the car class he seemed to like that answer. Though now writing this out I kind of realize that a color class isn't all that bad. But he then asked again what the benefit of having a color class is, and I wasn't sure. So I just said it allows multiple classes to share a similar color interface.
The other questions were about software debugging and those are boring. Anyways, just posting this so people can have a slight idea of what to expect in similar situations (it is a very large healthcare IT company that does software and hardware primarily) and to get some input on these last two questions and how you would have answered them. I'm pretty sure there were other interesting questions that I can't think of right now, if I do I'll add them.
EDIT:
Another question was very broad, and it was just how would I implement a game of checkers using OOD. I wasn't quite ready for this, and said I'd have a class for the board, a class tiles, an abstract base class Piece with derived classes for each type of piece.