On Sun, Jan 16, 2005 at 09:27:56PM -0800, Jonathan Lang wrote:
> How would I do the following in Perl 6?
Modulo any syntax foibles, I think it'd look like this:
>
> if a given condition is true for every element in a list, do something.
if all(LIST) > 3 { do_something }
>
> or
>
> if a g
Both of your questions are quite elegantly handled by junctions. If
the condition were, say, $elem > 10:
Jonathan Lang <[EMAIL PROTECTED]> wrote:
> if a given condition is true for every element in a list, do something.
if all(@list) > 10 { ... }
> if a given condition is true for any e