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

Re: Constructing 32-bit hexadecimal integers

by yakko (Friar)
on Apr 12, 2001 at 00:27 UTC ( #71850=note: print w/replies, xml ) Need Help??


in reply to Constructing 32-bit hexadecimal integers

Here's a way:
print hex(c030), "\n"; # prints "49200"
perldoc -f hex

Update: actually, on closer examination, you want to actually catenate 8-bit values into a big hex string. If this is the case, jeroenes has answered that above... I worked on a program awhile back in which I used something like:

$aschex.=uc(sprintf("%02x",ord($rawhex)));
... to get bytes that were raw hex values to display as an ASCII representation of hex.

--
Me spell chucker work grate. Need grandma chicken.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://71850]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (2)
As of 2017-09-24 03:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    During the recent solar eclipse, I:









    Results (273 votes). Check out past polls.

    Notices?