Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Compressing a set of integers

by I0 (Priest)
on Jan 26, 2003 at 16:47 UTC ( #229988=note: print w/ replies, xml ) Need Help??


in reply to Compressing a set of integers

foreach( @array ){ my @a = sort{$a<=>$b}split/,/; my $d=0; for( @a ){ ($d,$_)=($_,$_-$d); } $_ = pack'w*',@a; }


Comment on Re: Compressing a set of integers
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (13)
As of 2014-07-31 18:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (251 votes), past polls