New Beginnings and Amazon.com Interviews
March 6, 2007
I’ve been wondering if I should do this for a while. Make and maintain a blog that I’m quite aware no one will ever read. Eventually, with one or two people saying it’s a good idea, I’ve decided to officially throw my hat into the blogging ring.
For those of you who don’t know me, my name is Mark Stump and I’m a second-year Computer Engineering major at the Rochester Institute of Technology. I’m also a lab instructor for the Computer Science Department at RIT, which is fun job to do.
The trigger for the creation of this blog was a job interview I just had. I’m currently trying to enter the BS/MS (Bachelors/Masters Dual Degree) program that the CE department offers, which means I have to co-op this summer. Today I had a phone interview with Amazon.com, and I wanted to get out how it went and what was asked. I’m sure many people I know will go through processes such as this; I just got lucky with an early interview. The interview consisted of two parts: Technical questions and a long coding question. What happened in each part is explained below.
This part of the interview took about a half hour and consisted of a wide-range of questions, from basic Object-Oriented Programming concepts to advanced Java topics. I was able to get most of the questions, but one I completely borked when I shouldn’t have. That question is below:
Interviewer: “Explain the difference in Java between strings and string buffers”
Me: <Long winded, grasping-at-straws explanation>
Me: “That’s not even close, is it?”
Which was not a good way to start (this was my first question). However, things turned around from there. Another question I was asked was why Java now allows you to use Generics in collection declarations. While I wasn’t completely sure about this, I was able to come to the correct answer (allows Strong Typing). While I didn’t say “Strong Typing” exactly, I was able to explain the concept of it, which seems like that’s what really counted
A simple question that was given that I felt was easy (and made me feel smart) was to explain what a garbage collector is and what it does.
Finally, the most involved question I received was to design a complete Zoo with the concepts of OOP. This wasn’t language specific, just general conceptual-type stuff. I gave an answer of a large “Zoo” class where everything else would come together, and then other classes such as an “Animal” class (which sub-classes that inherit for specific species), a “Cage” class (sub-classes for different types of cages), and a person class with subclasses for different people (Spectator, employee, whatever).
The best advice I can give is to not get discouraged. Like I said, although I completely borked the first question which I probably should’ve gotten, I was able to recover and finish fairly strong.
This question could’ve gone down in a few ways. First, if I didn’t have enough time, I would’ve written out the code by hand and relayed the code over the phone, which had a really excellent chance of being an awful experience. Since I had the time, I was able to get the full version of the problem and probably show the interviewer that I have a decent grasp on the language I programmed the solution in and also that I have decent problem solving skills.
The question was this: Write a method (or methods) that take an integer and return the value as an English sentence. The number was to be between 999,999 and 0. This problem wasn’t overly hard, but it did take some time to complete.
To complete the problem, I was given about 2 hours, of which I took about an hour and a half to get a satisfactory solution (to me).
The method I attacked this problem was to use three methods, two of which returned string versions of basic numbers and the main driver method to convert the number and return a string. I’m not going to get into my solution for the problem (if you want, feel free to ask me for it, I’ll give it to you) since the logic behind, while I find it easy to understand, I suck at explaining stuff like this over the web.
Feel free to try it yourself; it’s actually a fairly fun, simple problem. I was able to do it a little under 200 lines of code (which comments I put in). My solution is probably bloated and given more time, I could probably trim the code to be a good deal more efficient and more compact. I was under the gun and a bit nervous, which isn’t an environment where I code the best. I was given the choice to do the code in any language any way I wanted. Java was the programming language I choose (I’m most familiar with it) and I also used the Eclipse IDE to test and code my program.
Anyway, that’s about all I have to say on this topic. I wanted to record my experience, and I hope the information I have helps at least one person with his or her own interview. If you have any questions or comments or whatever, feel free to contact me at firstname.lastname@example.org.
Now I get to enjoy the rest of my Spring Break. Ciao.