Sorting a hash to user needs

2009-07-08 Thread Alexander Müller
Hi, I need an order for hash by user preferences. Because the criterion to order the hash entries a not numerical and not should sorted alphabetical, I tried following   3 %hashToSort = (   4 a = one,   5 b = two,   6 c = three,   7 ); @keys = sort { qw(a, b, c) } (keys

pack function

2006-08-24 Thread Alexander Müller
Hello, I am currently trying to understand the TripleDES code and found the following line my @kvs = PPDES::des_set_key( pack( H*, substr($passphrase, 16*$_, 16 ))); which apparently processes a 16 characters large block with the pack() function. Now I would like to know what it exactly does