perlfaq4: How do I convert between numeric representations? 

"Using unpack; 
    $bin = unpack("B*", pack("N", 3735928559));  

Using Bit::Vector: 
    use Bit::Vector;
    $vec = Bit::Vector->new_Dec(32, -559038737);
    $bin = $vec->to_Bin(); "

RT(F)M,
.ted

-----Original Message-----
From: frank delatorre [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 05, 2003 8:24 AM
To: [EMAIL PROTECTED]
Subject: built-in perl function?


(I'm resending this email because I got a kickback for NON-delivery)

this is a REAL basic question. 

I need to do a conversion from DECIMAL to BINARY. Is there a built-in perl function 
for this?

thanks
-frank








Frank DeLaTorre
Chief Hardware Architect
xzuberant! Systems
408.390.0415
www.xzuberant.com
[EMAIL PROTECTED]



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to