in reply to Snarky comments on the ddj perl quiz
One has to marvel at the lack of proofreading behind:
What is the simplest type of data that Perl can work with? 1. element 2. scalar 3. vector 4. component and then (in the answer section): The simplest type of data that Perl can work with is called a scalar. +Answer: C.
There wasn't any answer "C" ...?! Oh, we're supposed to do a mental translation from numbers to letters!
There's also a typo, in question #9:
Which of the following commands should be used to open a filehandle na +med KAREN to an existing file named sw? 1. open KAREN ">sw"; 2. open KAREN, ">sw"; 3. open "sw" KAREN; 4. open ">sw", KAREN;
I didn't like any of them ... the only one that works (#2) overwrites the file "sw", whereas the question implies that the file is being opened for read access.
As does the answer (which doesn't match):
The command open KAREN, "sw"; should be used to open a filehandle name +d KAREN to an existing file named sw. Answer: B.
I've only read the first 16 of them, but it's not a test I'd be likely to use in an interview session.
Oh, and one final nit: I always think of arrays as going horizontally from left to right, but if they are vertical, then wouldn't:
Which operator can be used to take the bottom item from an array? 1. pop 2. push 3. pull 4. plant
Have it upside-down? If anything, push and pop should work with the top of the array, I'd think...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Snarky comments on the ddj perl quiz
by ysth (Canon) on Aug 23, 2007 at 01:17 UTC | |
|
Re^2: Snarky comments on the ddj perl quiz
by djp (Hermit) on Aug 24, 2007 at 04:34 UTC |