Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^2: Yet Another Rosetta Code Problem (Perl, Ruby, Python, Haskell, ...)

by jdporter (Canon)
on Aug 12, 2007 at 13:22 UTC ( #632054=note: print w/ replies, xml ) Need Help??


in reply to Re: Yet Another Rosetta Code Problem (Perl, Ruby, Python, Haskell, ...)
in thread Yet Another Rosetta Code Problem (Perl, Ruby, Python, Haskell, ...)

Excellent excellent excellent.
A solution to the order problem would be to use an order-remembering hash (e.g. Tie::IxHash). Or you could pluck out the even-numbered elements of the list, e.g.

$_ = 'abbbccddde'; @a = /((.)\2*)/g; @a = @a[ grep { not $_ & 1 } 0 .. $#a ];
A word spoken in Mind will reach its own level, in the objective world, by its own weight


Comment on Re^2: Yet Another Rosetta Code Problem (Perl, Ruby, Python, Haskell, ...)
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://632054]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (6)
As of 2014-09-17 22:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (100 votes), past polls