Saturday, August 16, 2008

Attention job candidates

Simple question - I encourage you to add a comment with your own solution in any language:

I have a file with one word per line, N number of lines. Count the number of times your name exists in the file. Use any language you'd like, just give me the number.

cat filename grep name wc -l

fopen, fread, strstr, fclose

load file, select count(*)

As a software engineer/progammer it's not hard, why have the last 8 candidates failed to answer this?!

No comments: