Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • by kasei (2524) on 2002.02.18 20:09 (#4687) Homepage Journal
    Hahaha... if the regex allowed moving to any adjacent pixel, you could write a regex to solve a black-and-white maze image ;)

    So going from the red starting pixel, to the green ending pixel travelling only on the white paths:

    print "yay" if ($image =~ /\N{red}\N{white}*\N{green}/);

    That would totally rule! I don't think mapping an image to a string would quite be feasible if you allowed adjacent pixels though... unless the string was lazily generated or something... wow - crazy thought!

    .g