Cracking the Coding Interview, 4 Edition - 150 Programming Interview Questions and Solutions
Cracking the Coding Interview, 4 Edition - 150 Programming Interview Questions and Solutions
Cracking the Coding Interview, 4 Edition - 150 Programming Interview Questions and Solutions
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
<strong>Interview</strong> War Stories<br />
The View from <strong>the</strong> O<strong>the</strong>r Side of <strong>the</strong> Front, by Peter Bailey<br />
For <strong>the</strong> eager c<strong>and</strong>idate getting ready for a big job interview, <strong>Cracking</strong> <strong>the</strong> <strong>Coding</strong> <strong>Interview</strong><br />
is an invaluable reference, containing excellent coaching <strong>and</strong> practice<br />
material that gives you an inside edge on <strong>the</strong> interview process.<br />
However, as you go over your old data structures textbook<br />
<strong>and</strong> drill yourself with homemade discrete math flash cards, don’t<br />
make <strong>the</strong> mistake of thinking of <strong>the</strong> interview as a kind of highpressure<br />
game show – that if you just give all <strong>the</strong> right answers to<br />
<strong>the</strong> tech questions, you too can win a shiny new career (this week,<br />
on Who Wants to be a Software Engineer?)<br />
While <strong>the</strong> technical questions on computer science obviously are<br />
very important, <strong>the</strong> most important interview question is not covered<br />
in this guidebook. In fact, it’s often <strong>the</strong> single most important<br />
question in your interviewers' minds as <strong>the</strong>y grill you in that little room. Despite <strong>the</strong> questions<br />
on polymorphism <strong>and</strong> heaps <strong>and</strong> virtual machines, <strong>the</strong> question <strong>the</strong>y really want an<br />
answer to is ...<br />
Would I have a beer with this guy?<br />
Don’t look at me like that, I'm serious! Well, I may be embellishing a little, but hear me out.<br />
The point I'm trying to make is that interviewers, especially those that you might work with,<br />
are probably just as anxious as you are. Nonsense, you say, as a nervous young professional,<br />
checking your pants for lint while you bite your fingernails, waiting for <strong>the</strong> interview team to<br />
show up in <strong>the</strong> front lobby. After all, this is <strong>the</strong> big leagues, <strong>and</strong> <strong>the</strong>se guys are just waiting for<br />
you to slip up so <strong>the</strong>y can rip you apart, laugh at your shriveled corpse, <strong>and</strong> grind your career<br />
dreams to dust beneath <strong>the</strong> heels of <strong>the</strong>ir boots.<br />
Right? Just like pledge week, back in freshman year? Right? Hmmm?<br />
Nothing could be fur<strong>the</strong>r from <strong>the</strong> truth. The team of developers <strong>and</strong> managers interviewing<br />
you have <strong>the</strong>ir own tasks <strong>and</strong> projects waiting for <strong>the</strong>m, back at <strong>the</strong>ir own desks. Believe me,<br />
<strong>the</strong>y’re hoping that every interview is going to be <strong>the</strong> last one. They'd ra<strong>the</strong>r be doing anything<br />
else. There might be a batch of upcoming projects looming on <strong>the</strong>ir calendar, <strong>and</strong> <strong>the</strong>y<br />
need more manpower if <strong>the</strong>y’re going to even have a prayer of making <strong>the</strong>ir deadline. But<br />
<strong>the</strong> last guy <strong>the</strong> agency sent over was a complete flake who railed about Microsoft’s evil for<br />
half an hour. And <strong>the</strong> one before that couldn’t code his way out of a wet paper bag without<br />
using copy-<strong>and</strong>-paste. Sheesh, <strong>the</strong>y think, where is HR getting <strong>the</strong>se guys? How hard can it<br />
be to hire one lousy person?<br />
While <strong>the</strong>y may not literally be asking <strong>the</strong>mselves “Would I have a beer with this guy (or gal)”,<br />
<strong>the</strong>y are looking to see how well you would fit in with <strong>the</strong> team, <strong>and</strong> how you would affect<br />
team chemistry. If <strong>the</strong>y hire you, you’re all going to be spending a lot of time toge<strong>the</strong>r for<br />
1 3<br />
<strong>Cracking</strong> <strong>the</strong> <strong>Coding</strong> <strong>Interview</strong>