in reply to Re: Testing & Using Bits
in thread Testing & Using Bits
my $bytes = 0x123456; print join(" ", map { sprintf "%#02x", $_ } unpack("C*",pack("L",0x123 +45678))), "\n"; print join(" ", map { sprintf "%#02x", $_ } unpack("C*",pack("L",$byte +s))), "\n"; #output: #0x78 0x56 0x34 0x12 #0x56 0x34 0x12 00
What did you expect it to do?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Testing & Using Bits
by Aim9b (Monk) on May 31, 2007 at 18:34 UTC | |
by FunkyMonk (Bishop) on May 31, 2007 at 19:49 UTC | |
by Aim9b (Monk) on May 31, 2007 at 18:54 UTC | |
by FunkyMonk (Bishop) on May 31, 2007 at 19:59 UTC |