in reply to
in thread shortest
Okay this rocks and I've voted for your code...
I think this is what's happening :
- perl -ne ''executes the one liner forever.
- the regexp substitutes each character using s/./ and /g.
- $& is the previous matches.
- &1 is evaluated in the trinary operator ? using /e.
- if &1 then replace with odd else replace with even
- print defaults to $_, the results of the regular expression.
but what I really wanna know
is: what is &1?