Thread pack/unpack Funktionen (3 answers)
Opened by squantes at 2006-03-22 12:33

esskar
 2006-03-22 19:13
#63940 #63940
User since
2003-08-04
7321 Artikel
ModeratorIn

user image
[quote=vayu,22.03.2006, 11:49]
Code: (dl )
$myHexVar = hex($myVar);


die zahl darf allerdings 32Bit nicht überschreiten. Sprich, nicht mehr als 8 Stellen haben.[/quote]
Code: (dl )
1
2
3
4
my $x = unpack('h*', 'abcdef1234567890abcdef1234567890');
print "$x\n";
my $y = pack('h*', $x);
print "$y\n";

View full thread pack/unpack Funktionen