On Fri, Feb 04, 2005 at 10:39:30PM +0100, Juerd wrote:
: Does this make sense?
:
: my @words = gather {
: for =(open '/usr/share/dict/words' err die) {
: .=chomp;
: next if /<-[a-z]>/;
: /$re/ and take { word => $_, score => %scores{ .letters }.sum };
: }
: } ==> sort { .<score> } is descending, { .<word>.length }, { .<word> };
The other problem with this that = binds tighter than ==> does. Once you
start with pipes you probably want to stick with pipes:
gather {...} ==>
sort {...} ==>
my @words;
or
my @words <==
sort {...} <==
gather {...};
or just go back to the tried and true:
my @words =
sort {...}
gather {...};
Larry