in reply to Re: ensure ALL patterns in string
in thread ensure ALL patterns in string

>Why do you want the shortest I find short more comprehensible in general...just the way I'm wired I guess. Irresponsible thank you for your solution.

Replies are listed 'Best First'.
Re^3: ensure ALL patterns in string
by ExReg (Priest) on Jan 25, 2016 at 15:20 UTC

    While the shortest may generally be the easiest to understand in most cases, that might not always be true. The motto of Perl is "There Is More Than One Way To Do It" (TIMTOWTDI). Quite often the SHORTEST way to do something is done in a rather obscure way. Perl is especially good for playing Golf with the code - where the winner is the one who uses the fewest characters to do a task. See Perl Golf 101's examples at the bottom. I think many of them are easier to understand before being shortened.

    I love coming to this site because I learn something new here each day. There are a lot of pro level Perl Golfers on this site, and it amazing just watching them driving or putting on the greens.