Help for this page

Select Code to Download


  1. or download this
    sub pack24{ substr( pack('l>', $_[0]), 1) };;
    sub unpack24{ unpack('l>', "$_[0]\0") };;
    ...
    2:  512
    8388606:  2147483136
    8388607:  2147483392
    
  2. or download this
    sub pack24{ substr( pack('l<', $_[0]), 1) };;
    sub unpack24{ unpack('l<', "$_[0]\0") };;
    ...
    2:  0
    8388606:  32767
    8388607:  32767