in reply to The perils of being tricky

Neat, but too tricky to actually use, in my opinion. It takes a few seconds just to parse it mentally and the order of the results is not very obvious. A more explicit piece of code would be worth the extra lines to me.

Replies are listed 'Best First'.
Re^2: The perils of being tricky
by other90percent (Sexton) on Jun 05, 2005 at 05:59 UTC

    I agree. If expect to use the code for more than once, I always take the time for readability. And I usually try to leave a comment line saying what I was thinking at the time, not how I wrote it that day - 'comment at the level of intent' as McConnell would say.

    For every Perl idiom, there is usually more than one way of writing it - TMTOWTDI, after all - and they will surely occupy different points on the readability spectrum. Not to mention the 'pedanticness' spectrum.