in reply to (Fixed) Mr. Regex Strikes Again!

In the future please note when things are only supposed to run under 5.6.x. There is no output under 5.005.
  • Comment on Re (tilly) 1: (Fixed) Mr. Regex Strikes Again!

Replies are listed 'Best First'.
Re: Re (tilly) 1: (Fixed) Mr. Regex Strikes Again!
by japhy (Canon) on May 15, 2001 at 18:06 UTC
    D'oh, yeah, because of (?{ ... }). Sigh. Ok, I'm saying what the program does, since it's been so much of a hassle already. It prints all sequences (not necessarily continuous) of a string:
    input: abcd output: a b c d ab ac ad bc bd cd abc abd acd bcd abcd


    japhy -- Perl and Regex Hacker
      Actually, there's also an empty line when you do this. Because of that, a better way to say this is that the output is the set of all subsets of the input list where the elements in the subset follow the order from the original list. This includes the trivial solutions of the empty set and the original set, in addition to all other non-trivial solutions. So that's some nice golfin' there :-)
      Dr. Michael K. Neylon - mneylon-pm@masemware.com || "You've left the lens cap of your mind on again, Pinky" - The Brain