Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re^2: mini-golf: convert integer into list of powers of two

by tobyink (Canon)
on May 24, 2012 at 12:30 UTC ( [id://972236]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    0        1         2         3
    12345678901234567890123456789012
    sub{grep$_,map$_[0]&1<<$_,0..31}
    
  2. or download this
    0        1         2         3
    1234567890123456789012345678901
    sub{grep$_[0]&($_=1<<$_),0..31}
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (8)
As of 2024-04-18 10:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found