Iterating over a hash slightly wrong when writing code in a google doc during an interview is such a stupid, trivial thing to be judged on, whether it's you or someone else doing the judging. It's clear from the "My lame attempt" example that the basic concepts are understood, and if he's written a series of articles about the Enumerable module then he probably knows it better than the majority of professional developers working with the language.
If this is a serious article, then it really highlights everything that's wrong with tech interviewing.
A programmer without a portfolio of source code is like a painter without a portfolio paintings.
I assume Google scouts are usually looking to hook the exceptionally rare "Monet" and "Picaso" software engineers swimming around in an ocean overcrowded by "PC techs".
There is a quote by Linus Torvalds that is fairly relevant here. "Talk is cheap. Show me the code."
Your resume is nice... Cute even. But without the code to back it up, there is nothing to critique your actual skills.
Perhaps another side is that he didn't seem to be guided to the correct solution during the interview process, which would concern me more than not getting it right first time if I were hiring.
CRUMB : BREAD :: (A) ounce : unit (B) splinter : wood
How much confidence would you have in a version of the SAT that was reduced to just one question which determined the entire score?
It's exactly analogous to tech interviewing. It's like saying, oh he couldn't even get that analogy right! He can't do analogies. Same thing with giving people one programming question. Much less nitpicking that one question...
So we are forced to go on lots of interviews and just hope that we happen to quickly grok the one or two problems they give us -- so we'll look "perfect" in that short period of time. which is eventually almost certain given enough interviews. but you can't be super confident to pass any particular interview you might have had your hopes on.
Looking back, it was pretty silly but man did it really kill the confidence of 19 year-old me when it took me 10 minutes to work out that it detected numbers that were powers of 2. It really gave me a negative impression of Google's interview process (that and the complete radio silence afterwards), which I still think about when they send me their bi-annual recruiter emails. Funnily enough, the last email I got specifically mentioned that I had "done really well in the recruiting process in the past".
Umm, sorry, no. You wouldn't believe what kind of 5-level-nested-if C++ statements you could find in Google's codebase. Google might be known for its technical abilities, but "affinity to functional programming ideas" is generally not one of them.
Programming languages are powerful things with which you can do a lot of very different things and tackle very different issues. Sometimes it's database querying, sometimes complex data structures, sometimes parallelism, genericity, business data modeling, etc. etc.
There should be a list of "warm up" exercises somewhere to help people prepare for general tests and make sure they've touched at least every subject once before going live.
Also, did you not sign an agreement with Google that you wouldn't share interview questions before you started interviewing? I think sharing questions is generally considered somewhat uncool.
People who reject physical reality should receive a bit of negative conditioning about doing so...
He should have chosen a language he is better at. If Ruby is indeed his top language, and he's rusty at that, then perhaps OP just isn't fit for a coding job at this point in time?
- A language with a REPL so that I could check my ideas in a terminal window. - A language that would reduce the amount of typing I'd have to do - A language I that I was half-decent at (at lease at one point)
And Ruby fit all those criteria.
"So, I found your resume... blah blah blah, you say you've done XYZ, blah blah blah, send me a copy of your resume."
WTF?
I said "um... you're google - don't you already have all my information?" a bit jokingly, and she laughed a bit. I then told her I wasn't at my computer, but if she Binged my name, my site would come up, and she could grab a resume from there. A few mumbles later, I got "OK, got it! I'll get back with you in a couple days with the answers to those questions!" I'd asked a couple questions about the job. That was early August - no followup. As unprofessional as any other hack recruiter imo. I guess I shouldn't have expected more, but I did.
tldr: I told Google to Bing me.
"Do you have a more recent resume available? The one I have looks like was last updated in 2007" would be far more respectful - it would show you're looking at it, parsed it out, and are giving the other person a chance to polish things up if they want.
"HEY! I just found your resume! .... Send me your resume!"
"Waiter... I was just looking at your menu... things look really good. Could you please bring me your menu?"
It just sounds stupid.
A good engineer spends about 95% of their time discovering new things to learn about their craft. An even better engineer uses what other engineers have already discovered and shared with the world to further their understanding.
If the world only consisted of the "even better" engineers things like this wouldnt ever exist. http://swtch.com/~rsc/regexp/regexp1.html
When I hear, "I want you to develop a mini google.", I feel that the only right answer to the question is, "No thats not a problem that needs to be fixed anymore. Lets actually fix a real world problem that affects real world people."
There are very few new generation software engineers that are truly hackers at heart. Its really sad when a company like Google doesnt even know how to look for them anymore.
If Google just wanted people to take existing publicly known parts and hook them together, they would be recruiting people fresh out of community college instead of fresh out of masters and PhD programs, and they'd be offering around $50k/year salary.
Google is trying to find people who can create the parts that ordinary programmers hook together.
Also, having the "this is not a problem" attitude is a red flag; what else would this person not consider a problem when I hire them?
If you honestly are looking for a job and aren't looking to make some kind of F-U 2 The Man statement, do yourself a favor and don't give an answer like that.
If you were asked to write a regex engine as an exercise you'd say "No thats not a problem that needs to be fixed anymore."?
How would you expect to be able to improve performance of regex engines without understanding how a basic regex engine works?
http://en.wikipedia.org/wiki/Inverted_index
As for the interview, I really wouldn't sweat it. Even if you didn't do well in the eyes of your interviewer, 1. there are several interviews that they are looking at, not just one, 2. people understand that folks get nervous and can screw things up sometimes, and that whiteboard (or google document) coding isn't the best measure of intelligence. Because of this, they're usually more interested in how you respond to feedback than the merits of your first attempt, and 3. there's a lot of luck to any interview process - what questions get picked, etc. and even if you don't do well I wouldn't discourage you from trying again in the future.