Well, I don't want to embarrass him too much, but his approach was to step through the array, look at each element and guess whether it was meant to be a key or a value, then use a '$last_key' variable to put the value into a new hash. There's also quite a bit of warning code in his routine, leftover from debugging.