in reply to Re^5: Create reference to sorted anonymous array
in thread Create reference to sorted anonymous array

Eww... Seeing that ensures me to stick with the C-Style loop. :P
Honestly using grep to determine whether to print out the next element or not is... wow. :P
  • Comment on Re^6: Create reference to sorted anonymous array

Replies are listed 'Best First'.
Re^7: Create reference to sorted anonymous array
by Your Mother (Archbishop) on Mar 18, 2016 at 13:24 UTC

    After you've been doing Perl for awhile you'll probably never want to see the C-for loop again. Perl style and idioms might be a little jarring at first but they are very readable once you get used to them and, I argue, lead toward more compact code in the loops which, for me, is easier to follow and debug. I'd rather see 5 lines of good/common idiom than 20 lines of plodding obviousness.... The more dense one is actually easier to focus on and not miss things, for me, anyway.