in reply to The importance of underscores

There is no output. ActiveState 5.6.1 build 633.

[Added split /\W+/ splits the entire string which ends just before the print() at the end. Each element of the result from split() is a fragment of text that appears to be perl code but really isn't. The y...c fragment adds the string length to the $, length which is used as the offset parameter to the vec function.

Each part of the input is an incremental offset to a bitstring being built up by vec in $\. The actual bits are being set by using vec as an lvalue via the ++ operator.

The lone print at the bottom outputs nothing followed by the output record separator $\ which just happens to include the desired text.

Bravo! That was a very clever expression.]

Replies are listed 'Best First'.
Re: Re: The importance of underscores
by thelenm (Vicar) on Mar 25, 2003 at 19:46 UTC
    Ack! I only tested with 5.6.1 and 5.8.0 on Linux. Thanks for the praise, and good job with the deconstruction.

    -- Mike

    --
    just,my${.02}