Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^2: built in function for binary division

by ghosh123 (Monk)
on Jan 11, 2013 at 05:44 UTC ( #1012798=note: print w/ replies, xml ) Need Help??


in reply to Re: built in function for binary division
in thread built in function for binary division

Hi Kenosis,

Yes, this is what I meant. Is it possible to do by any built-in perl function ? Else any hint to achieve that ?
Thanks.


Comment on Re^2: built in function for binary division
Re^3: built in function for binary division
by Kenosis (Priest) on Jan 11, 2013 at 05:52 UTC

    You can work with binary numbers as shown, viz., by preceding the number with 0b, performing the operation, and then formatting the result using sprintf.

    Were you thinking of some other binary math function?

      Hi Kenosis

      Yes I was looking for some binary math subroutine for this, but what you have shown by preceding 0b is also fine.
      Thank you !!

        You're most welcome, ghosh123!

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2014-10-31 06:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (215 votes), past polls