in reply to Re: Variant of map for special-casing the last item
in thread Variant of map for special-casing the last item
I definitely like the use of a state variable way more than the 5.8 approach. But what I still don't like about this and similar solutions is that they introduce a dependency inside the code block on the value of $#in. What if the input list isn't in an array variable? That's right — you can store it in a temporary. Well, that's what my solution does for you, keeping that mess out of your code.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Variant of map for special-casing the last item
by kcott (Archbishop) on Oct 26, 2010 at 18:34 UTC |