in reply to Re: Regex failure interpretation
in thread Regex failure interpretation

Not quite. As I mentioned above, I only want to capture the first character, not the whole string.


Examine what is said, not who speaks.
"Efficiency is intelligent laziness." -David Dunham
"Think for yourself!" - Abigail

Replies are listed 'Best First'.
Re: Re: Re: Regex failure interpretation
by tachyon (Chancellor) on Mar 20, 2004 at 00:45 UTC
    $_ =~ m/^([01])[01]*$/ and print "$_:'$1'\n" for qw[ 0 1 00 11 10 01 0 +12];

    cheers

    tachyon

      I knew that:)


      Examine what is said, not who speaks.
      "Efficiency is intelligent laziness." -David Dunham
      "Think for yourself!" - Abigail