I was interviewing with a "too proud of my java skills"-looking person.

  1. He asked me "What is your knowledge on Java IO classes.. say.. hash maps?"

  2. He asked me to write a piece of java code on paper - instantiate a class and call one of the instance's methods. When I was done, he said my program wouldn't run. After 5 minutes of serious thinking, I gave up and asked why. He said I didn't write a main function so it wouldn't run. ON PAPER.

  3. [I am too furious to continue with the stupidity...]

Believe me it wasn't trick questions or a psychic or anger management evaluation thing.

I can tell from his face, he was proud of these questions.

That "developer" was supposed to "judge" the candidates.

I can think of several things:

  1. Hit him with a chair (which I so desperately wanted to) and walk out.
  2. Simply walk out.
  3. Ridicule him saying he didn't make sense.
  4. Politely let him know that he didn't make sense and go on to try and answer the questions.
  5. Don't tell him anything, but simply go on to try and answer the questions.

So far, I have tried just 4 and 5. It hasn't helped. Unfortunately many candidates seem to do the same and remain polite but this lets these kind of "developers" just keep ascending up the corporate ladder, gradually getting the capacity to pi** off more and more people.

How do you handle these interviewers without bursting your veins? What is the proper way to handle this, yet maintain your reputation if other potential employers were to ever get to know what happened here? Is there anything you can do or should you even try to fix this?

P.S. Let me admit that my anger has been amplified many times by the facts:

  1. He was smiling like you wouldn't believe.
  2. I got so many (20 or so) calls from that company the day before, asking me to come to the interview, that I couldn't do any work that day.
  3. I wasted a paid day off.
  • 18
    This doesn't strike me as being a particularly constructive question. The situation isn't unique to developers either. – ChrisF Mar 4 '11 at 13:38
  • 8
    @ChrisF - I think it is constructive, and while it's not unique to developers, it is certainly applicable to developers. – Joel Etherton Mar 4 '11 at 13:57
  • 12
    @ChrisF - This applies to techniques in interviewing and a situation which developers in search of a job frequently encounter. To take your metaphor to a different level, questions of design and architecture are often vague enough to be applicable to any number of disciplines (marketing, economics, print graphics) which makes them not unique to developers yet they are allowed all the same. Let the community draw the line on "constructive". This question has clearly sparked at least some meaningful dialog indicating its constructiveness. – Joel Etherton Mar 4 '11 at 14:08
  • 14
    Jeez, imagine being managed by a prick like that. – 5arx Mar 4 '11 at 14:43
  • 15
    A main() method won't help, you still need to install a JVM on the paper :P – Martin Mar 5 '11 at 23:22

22 Answers 22


Move on. It is hard, I've been there.

Interviewers like that are a dime-a-dozen. They ask you ridiculous questions thinking that is a real test of a good candidate. In fact, all they are doing is feeding their insecurities.

The last thing you want to do is blow up at the interview or lodge a complaint against the interviewer with their HR. That will only worsen their impression of you -- and trust me, you don't want that reputation preceding you (-:

Save your professional reputation, and take it somewhere else. Good luck with your job search.



Edit: Had to share this: http://theoatmeal.com/comics/interview_questions good for Friday PM laughs.

  • 16
    I agree with this one. Even in large cities, the IT market is a small world and things can get around. Let it boost your confidence that you know more than the interviewer and take it as a good thing you will not be working for him/her. Never act unprofessional in an interview and never try any form or retribution... it will come back to bite you. – cjstehno Mar 4 '11 at 15:26
  • Along those same lines - you are absolutely corrent that it's (IT's) a small world. The thing I would add is that you will not be working for (or with) him yet - in a small IT world, you may cross paths again some day. – Wonko the Sane Mar 4 '11 at 15:40
  • 1
    @KM01 thanks for letting me know that it is actually OKAY and a practical decision to just put up with it and move on. I thought I was weak if I did that. But apparently it is a sensible thing to do.. – user19224 Mar 5 '11 at 5:22
  • 1
    While at one level I agree, I wonder about our responsibility to call these people out and correct them. While that isn't your or my personal responsibility, what is our duty to our corporate (and I do not mean to a corporation here) responsibility? – Jordan Mar 5 '11 at 7:17
  • 6
    It reminds me of the perfect answer I've never have the guts to use - Q: Where do you see yourself in five years? A: celebrating 5 years anniversary from the day you asked that question. – HuBeZa Mar 5 '11 at 17:16

Laugh along with him.

"Oh yes! No main() function. Also, it's written on a piece of paper, which couldn't execute code anyway. And I forgot to draw a 'Compile' button. Ho ho, we're funny guys!"

Then try to move onto the next question. Yes, he is nit-picking, but it's really nothing to get upset about.

Make it apparent that you think the answer he was looking for was so obvious to you that you didn't think it worth mentioning. He's probably interviewing a range of candidates from programming geniuses through to people who've never programmed and are just desperate for a job. Sometimes as an interviewer it's worth checking the obvious.

  • 10
    ... obviously he was going to scan it, automatically compile and execute it with their inhouse "interview" scanner. – Steven Jeuris Mar 4 '11 at 13:13
  • 6
    +1 I really should develop that skill. I've seen people successfully employ this, but I haven't been able to do it myself :| I just get annoyed too easily and too quickly to do this.. – user19224 Mar 4 '11 at 13:17
  • 21
    I wish I could +1 again.. I still haven't stopped laughing at "Ho ho, we're funny guys!"... :D – user19224 Mar 4 '11 at 13:29
  • 10
    Being able to respond positively to criticism - even if it's not particularly helpful criticism - is definitely a good skill to possess. – Ant Mar 4 '11 at 14:33
  • 19
    Don't forget to draw Eclipse around the paper, then click on the "Run" drawn button with your finger... Then admit that, indeed, it will not run. – Philippe Mar 4 '11 at 14:36

If you encounter something like this, treat it like a trick question. Once the interviewer has "caught" you in whatever little trap he believes he's caught you in, casually explain what you did, why you did it, and if his response/direction/answer is incorrect, explain to him that you considered doing it that way then remembered {insert reason why it's incorrect} and decided to go with your method.

Try to avoid attacking words like "your way is wrong", "it's not right", "that's incorrect". If you point out an error in his tests without condescending or insulting the interviewer, it may actually make you appear to be a stronger coder.

You also have to consider that this person is likely to be your new supervisor, and if this person is taking such delight in fooling/besting/whatever someone, then is that really someone you want to work for? A person such as this is unlikely to want you working for them even if you are a superior coder specifically because it's apparent that his ego is running full amok. That kind of person can't stand having people work for him who know more, are better at the job, etc.

In the end, your best action is to maintain professionalism in the face of unprofessionalism. Regardless of his actions, carry yourself with a bearing that indicates you're sure of yourself and your responses without regard for his demeanor or possible uselessness.

  • 31
    +1 for "best action is to maintain professionalism in the face of unprofessionalism". – Steven Jeuris Mar 4 '11 at 13:14
  • Amen to "best action is to maintain professionalism in the face of unprofessionalism" – Jordan Mar 5 '11 at 7:23
  1. Politely tell him that you are not interested in working with him (you are not, trust me), and walk out. Contact the HR department that you might be interested in the interviewer's job, as soon as they kick him out for his obvious incompetency.
  • 39
    +1 for contacting HR and letting them know why you don't wish to work there. – Tyanna Mar 4 '11 at 13:40
  • 11
    Indeed, letting HR know, but don't be bitter when giving the feedback – Philippe Mar 4 '11 at 14:33
  • 24
    Developers consistently mock HR departments and now we're going to use them to tattle on our interviewer? Yuck. Just walk away. If the interviewer is an idiot, the people that put him in that position are likely idiots as well. Don't tattle. It's unbecoming. – Corbin March Mar 4 '11 at 16:52
  • 2
    The only way someone like this will get the message, is if people communicate it to people who can deliver it to him. – Jordan Mar 5 '11 at 7:22
  • 1
    Metro Smurf: I wrote "6." (to continue the list given in the question) but the forum software changed that to "1." – user281377 Mar 5 '11 at 11:00

You already have a job, and that makes you powerful. Remember that. You don't have to get the job, and you want a job that's better than your current job.

I once had a guy call me out for using "elsif" instead of "else if". The reason it pissed me off is because I was applying for a Perl job, and I'd just spent 15 minutes writing Perl code on a whiteboard.

Then he asked me how to do the same thing in java, and I scratched it out (without a main method, because wtf, who would care about that? That's the most pissant question...I digress), and the whole thing was right, except my brain was still in perl mode, and I did "elsif."

The little shit was so proud of himself. I shrugged it off, and he started asking questions about why I wasn't "bothered" by my mistake, and when I said it was a trivial syntax error that the compiler would catch, he's got red and started making, "You've got a bad attitude!" noises, at which point I thanked the other interviewers and walked out.

They actually called to offer me the job (I guess I was an early interview, so I must have looked good after the other schmucks), and when I turned them down, I specifically said I didn't want to work in an environment where I was going to take serious criticism for a simple syntax error.

  • 38
    People forget that an interview is a two-way process. You're interviewing them just as much as they are interviewing you. – Zoot Mar 4 '11 at 15:10
  • 3
    +1 - As @Zoot noted, interviews are a two way process and at the end of the day, the company should not be treating you like they are doing you a favor by interviewing you. Mutual respect during the interview process generally carries over to when you start the job. – rjzii Mar 4 '11 at 17:05
  • 1
    This is the ideal outcome for such a situation: when you get a job offer, don't need to accept it, and are able to politely decline and tell them why. – Carson63000 Mar 4 '11 at 20:41
  • 4
    @carson: The worst I ever experienced was with some consulting company in New York City...They told me that an efficiency expert had told them their productivity would go up 20% if everyone used their mouse with their left hand ONLY, and that, should I be lucky enough to be offered the job, I'd have to learn this "skill". Needless to say, I didn't stick around. – Satanicpuppy Mar 4 '11 at 20:45
  • 1
    @Graham: The complaint was about a Java syntax error. – Keith Thompson Oct 27 '11 at 18:12

Tell him that HashMap is not an IO class, smirk like a fool and then check into anger management classes.

  • 1
    Lol... I thought that one was pretty funny too. I would've had to at least politely correct them on that one. – cjstehno Mar 4 '11 at 15:28
  • 1
    Instead, humbly ask him what is his definition of IO classes and why HashMap belongs to that category. – Codism Mar 4 '11 at 22:12

I discovered at one of my previous employers that some interviewers actually ask questions, or phrase problems, in a way designed to provoke a bit of irritation. Those interviewers want to see how you react.

I once interviewed with someone who, in a question about implementing a battleship-like game, suggested that I plot each part of a boat placement and roll back the changes if there was a collision. I said that I probably wouldn't do it that way; I'd probably check each part first, and only plot if there was no collision, because it would be much simpler to implement and slightly less costly in the worst case, with only a trivial cost in the average case. He actually preferred that I politely "argued" with him than if I had just done what he said, because people who think through their design decisions are more valuable than people who just do what they're told. Nearly every full interview loop at that company that I've heard of involved something where the candidate was better off proposing an alternate solution or disagreeing with some assumptions behind a question.

So the lesson is this: If you're able to make a sensible counter-argument with a well-reasoned points without coming off as a complete jerk, do.

My answer to the first question you had would be something like this: "Well, for one, Hashmap isn't an IO class. But it is useful part of the collections framework when you want fast lookup of key/value pairs. It's not synchronized, so you'd need to wrap it in Collections.synchronizedMap if you want to access it from multiple threads. Alternatives to HashMap include..."

That being said, based on your specific scenarios, I'm not convinced that your interviewer was trying for that kind of sophisticated interviewing tactic. There's a kind of pedantry which is useful in software development (I'm quick to correct misuse of terminology, and I don't mind when people correct my own, because a common language is important for collaboration in our line of work), and there's a kind which is just smug and self-congratulating. In your case, the only sensible response to the second question would have been to chuckle in agreement, and maybe a good-natured comment about it being more important that your unit test passes.

I've interviewed candidates that have taught me something, and I always rate them higher than candidates that just answer the questions. Given a choice, I'd rather hire someone smarter than me. But I don't like asking questions meant to prove my own cleverness. (For one, I'm not that clever under pressure). I prefer to ask questions that help to evaluate problem-solving skills, and the ability to describe the line of thought that went into a proposed solution effectively.

  • 1
    +1 to " Given a choice, I'd rather hire someone smarter than me. But I don't like asking questions meant to prove my own cleverness. (For one, I'm not that clever under pressure). I prefer to ask questions that help to evaluate problem-solving skills, and the ability to describe the line of thought that went into a proposed solution effectively." – Jordan Mar 5 '11 at 7:33
  • +1 Awesome answer. You won't know immediately if the interviewer is "playing psych games" or is actually not qualified to work a spreadsheet, much less hire techies. Always speak truth to power, politely. The end result will always be positive for you. – Paul Sasik Mar 5 '11 at 14:34

It depends on if you actually want the job or not.

If so, point out why you were confused about the question, and offer a way to make his requests clearer in the future. Avoid terms that place the blame on him, and instead try and explain why you were confused with his request. By doing so you show your intelligence, communication ability, and can negate any negative opinion they might have formed from you not getting the previous question. Also, we have to work with technologically stupid people on a regular bases, and showing that you lose your temper over it is a bad idea

If you don't want the job, I would just say OK and let him finish his questions. Politely finish up the interview as fast as possible and get out of there. I wouldn't do anything to burn bridges because you never know if you might want another job with them, or what other companies they network with.

Don't forget, interviews are not tests where you need to get every question right to pass. I've actually seen someone do interviews where 95% of his interviewees answered the questions incorrectly, and he was fine with that.

  • 3
    Actually from the time the interview started, my willingness to work there started being inversely proportional to the square of the amount of seconds that has passed. No way I was going to take that job :D – user19224 Mar 4 '11 at 13:14
  • 2
    +1 for "interviews are not tests where you need to get every question right to pass." When I interview people, the moment I sense a good candidate I start with really hard/impossible questions just to see how they handle them. A job interview is much more than a test. – Nemanja Trifunovic Mar 4 '11 at 13:44
  • @Senthil I can understand that in your situation, but I know in other cases the job might have something the candidate wants... location, salary, experience, etc. The interviewer doesn't always ask good questions and I think its a good idea to know how to react to bad questions. – Rachel Mar 4 '11 at 13:52
  • @Rachel Yes that is so true. I am from India where the sheer number of "talented people" available tilts the scales in favor of the companies.. but fortunately for me I wasn't desperate to get that job. – user19224 Mar 4 '11 at 13:54
  • Once you decide you don't want the job, it makes sense to politely say you don't think it's a fit, and you don't want to waste any more of their time, and leave. Just be polite about it. – David Thornley Mar 4 '11 at 14:36

Just remember that interviews are as much tools for the interviewee as they are for interviewer. You should be evaluating the entire time whether the job seems like a good fit for you.

If you think your interviewer is an idiot, then in a way he is doing in a favor by letting you know that you probably don't want to work with him.


Be Thankful

That you found out about it [incompetence/arrogance] before you took the job.

I'd say you dodged a serious bullet!


Never suffer fools.

Likewise, never work with them or for them.

  • 5
    Find me a company that doesn't have at least one village idiot... – Wonko the Sane Mar 4 '11 at 15:44
  • 1
    @Wonko - that is true, but you don't have to put up with them and especially try not to work for them. – JeffO Mar 4 '11 at 16:39
  • @Jeff: I agree with the second half (or at least the "try" part), but disagree with your first part. Putting up with people you disagree with is an important part of any job, programming or not. – Wonko the Sane Mar 4 '11 at 18:03
  • 1
    Putting up with people that are wrong is flat-out different than putting up with people you disagree with!!! – red-dirt Mar 4 '11 at 22:56
  • 2
    @Wonko the sane - @el fuser I disagree with many people that I think are brilliant and have a lot of respect for. – JeffO Mar 5 '11 at 3:15

Once in a post interview while talking to a human resources representative I noted that while I had a favorable impression of everyone I talked to and they seemed like a good group to work with, it was an interview so everyone is likely on their best behavior and you really don't get to know people until you have been working with them for awhile. All that said, it leads directly to my point: if you don't like the people that are interviewing you, odds are you will like them even less once you actually start working with them on a daily basis.

If the interview is going very badly and it is a long (i.e. full day panel interview) interview then I would likely look for a point in which you could politely take the person leading the process off to the side and state what your concern is. Depending upon how that goes (i.e. if the person that left a negative impression is from another group then it might make sense to press on) I would simply let them know that you would like to end the interview early and if they ask why just politely tell them that you don't think you would be a good fit with the corporate culture. If they ask for more details beyond that it's up to you if you want to answer them, but generally the less you say the better as they have everything to gain from your responses and depending upon what you say it could hurt your reputation.

  • 1
    +1: ...If you don't like the people that are interviewing you, odds are you will like them even less once you actually start working with them on a daily basis. - 100% correct. – Jim G. Oct 26 '11 at 16:25

Call him on it

Reason with him — something like the following. If he's worth working for, he will bail out after one of your responses and see the flaw in his previous interrogation. If he makes it to the end of this hypothetical scenario without seeing reason, well, walk out.

You: Oh, I'm sorry, I didn't realize that you wanted me to include the main method.

Him: It's not going to run without a main method, so why wouldn't you include it?

You: I realize that at some point execution needs to start, but I had in my mind other scenarios, such as a server, where execution had already begun.

Him: That is no justification for code that won't run.

You: Clearly you see some problem here. Do you believe, from this experience, that I have indicated my lack of knowledge about main methods?

Him: Yes. (you should walk out)
Him: No...

You: Then, please help me understand what the problem is.

Hopefully at this point you can have a reasonable discussion. If not, again, it's not worth your time.


Don't ever do options 1 and 3. It may feel good to vent your anger, but it doesn't solve any problem (instead, usually just makes it worse). It is easy to condemn stupid looking people but without knowing the big picture, it may be a simple mistake. And all in all, that just pulls you into the emotional whirlwind, thus making you part of the problem.

I would probably go with option 4 at first. Some people may be able to learn from feedback and become more sensible. But if it doesn't seem to work out, switch to option 2. There is no point wasting my time and effort on trying to change people unwilling to change. And even less trying to prove to a person that I know better, if (s)he is unwilling to admit it ever.


I've had a similar interview, except that I tried to take the guy through my code. His response was to blow up, and shout that he had a team of [10? 15?] developers, and that I "didn't have the attitude to work in [that] environment". My response? Walk out.

  • 2
    His company is probably owned by his uncle. – JeffO Mar 5 '11 at 3:18

If I would have been you, I would have done 5 (saying that it was stupid mistake by me). And then to the HR I would have given very much negative feedback about the interview. Also if possible I would tell the other people (like you did) about this incident along with the company name (as you didn't) and will warn them.
I will never do 1,2 as it is not professional. Will never do 3 and 4 because I am not responsible for his/her stupidity and it's not my job to make him/her better.

  • Passive aggressive? – TRiG Mar 4 '11 at 20:02

From experience, they're trying to catch out the textbook-type developers from the "I eat code" developers. Many developers fail these dumb questions (no joke).

Also, there are situations where if they hire a (Jon Skeet) type developers, i.e. the developer is smarter than the interviewer, the interviewer finds it a threat and eliminates the interviewee for job security sakes (many times, the interviewer is the chief architect or team leader).

It's a catch 22. Just walk out, and tell HR to shove the job where the sun don't shine (in a polite manner of course). Tell them you know Jon Skeet....lol

  • This, definitely. Interviewers are usually afraid to hire somebody smarter than them, especially if they are in a lead/manager type of role, because the smarter person might end up getting their job or proving them to be incompetent. – Wayne Molina Oct 26 '11 at 13:12

Well I read somewhere once that in this situation you can tell him a story. The main thing is that the story looks like is not about him, but he will know that it is about him. This is kind of subliminal messaging. You are just telling the story but in his subconscious mind he knows that you are talking about him. So the story would be this:

"Oh, this reminds me of a candidate who did such a funny thing. He had an interview with a so smart a** guy and eventually the candidate hit him in the face and left the room. The interviewer was shocked and realized that something is wrong with him..."

  • 1
    So, you are choosing #1, but verbally? – Wonko the Sane Mar 4 '11 at 15:48
  • Well...not exactly. I think you don't see the point. – Adam Arold Mar 5 '11 at 14:18

Been There. As you already know, he (she) is trying to probe he nows more about Java than you, by "downvoting" your answer (ever watch movie "Amadeus" with the "Salieri" character ?).

Politely remember him / her, that you are there to get a job, not to test who know more about Java / (whatever technology), that it's ok for you to try to impress the interviewer, because you are looking for a job, and that each person may solve a problem in a different way from others, and that doesn't necessarily means that is a wrong answer.


I answer all questions during an interview, even idiot ones. For example, in a recent interview (I applied for a Software Architect position and the interviewer is a Technical Architect, according to his title) I got a question to list out all versions of the .NET framework has been released until .NET4. No problem, I even gave the interviewer more when telling him that I used .NET Framework from its early beta in 06/2000 :).

  • WHat possible use would listing all possible version of the .NET Framework serve exactly? Of course I also have been using .NET since I think the last Visual Studio .NET Beta so I likely could list most of them from memory. – Ramhound Oct 26 '11 at 11:46
  • I don't know too and I didn't bother to ask him why he asked me this question :). – Tien Do Oct 27 '11 at 4:51

The test may be how you answer the question, and deal with the "obviously wrong" person in authority, a boss, a customer, a co worker, a customer...

  • 1
    -1: Even if you pass such a test, would you want to work for such a person? – Jim G. Oct 26 '11 at 16:21


The interviewer is always right. Then go on programmers.SE to vent :)

  • I'd be more interested in a candidate who disagreed with me and could back up their position. Unlike some, I don't believe posting a job means you host an ass-kiss festival. – JeffO Mar 5 '11 at 3:17
  • 3
    …following that, go onto meta.programmers.SE to vent that your programmers.SE rant was closed. – kojiro Mar 5 '11 at 20:38