On 01/10/17 16:09, Steven D'Aprano wrote: >> The fizzbuzz one is definitely a bit too simplistic, but the one >> cited by McConnel (reverse a linked list in C) is typical of >> the kind of question we used. And yes, most candidates failed. >
> I would have *no idea* how to traverse a singly-linked list in reverse > without making a copy of it first. The point is you don't need to traverse it in reverse you simply iterate over it from the first element and prepend each node. It really is trivially simple - or should be for anyone purporting to be a C programmer. And its not about memorizing algorithms - I never would expect that - its about looking at the problem and thinking about the solution. And I should add that I was last interviewing programmers in the 1990's (for the millennium bug the very last time, and the code was in COBOL!). But to address another issue raised by Mats: > Probably the best programming test there is look at code > that's already been developed, Very true and in an ideal world what you would do, but... It is what we did with the bug finding test. But, as alluded to by Steve, it's really hard to do this for anything significant in an interview, since you would need to be familiar with the system's framework and libraries since most code consists of calls to libraries. And the candidates will probably not all be familiar or even aware of such, so, to level the playing field, you give them a simple but generic problem, like the fizzbiz or linked list tests. > ...not nearly all of the important skills of the > professional programmer are in code Absolutely, or at least for the software engineer. There is I believe a big cultural difference between, say the UK, and the USA in what a programming job looks like. (I'm less familiar with other countries, even in Europe) In the UK a "programmer" is a code monkey who takes a code spec (flow chart or pseudo code) and turns it into industrial strength code. It's a low paid (relatively) position and the programmer probably does not have any computer related degree, maybe a craft school diploma. I believe programmer salaries are currently around £22-25K per annum. A software engineer can program but is also supposed to be able to capture and analyze client requirements produce a top level design/architecture, develop low level design/spec (possibly for handing to a "programmer") write the code, test it completely ("programmers" only do unit tests, not system tests) and write appropriate documentation. Salaries here range from about £30-60K per annum depending on experience etc. When I was interviewing it was always for software engineers - we only employed programmers in our mainframe systems. Everyone else was an "engineer". So I guess expectations for the role might have a big bearing too. -- Alan G Author of the Learn to Program web site http://www.alan-g.me.uk/ http://www.amazon.com/author/alan_gauld Follow my photo-blog on Flickr at: http://www.flickr.com/photos/alangauldphotos _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor