#results 0000000100100011010001010110011110001001101010111100110111101111 -> iL1@; #### #!/usr/bin/perl use strict; use Math::Base85; my $str = "0000000100100011010001010110011110001001101010111100110111101111"; #binary to decimal conversion my $num = unpack("N", pack("B32", substr("0" x 32 . $str, -32))); print "$num\n"; my $m = Math::Base85::to_base85($num); print "$str ->\t$m\n"; #decode it ############################################## my $q = Math::Base85::from_base85($m); print "back to decimal ->\t$q\n"; #I'm losing a 32 bit chunk here my $str1 = unpack("B32", pack("N", $q)); print "back to bin ->\n", $str1,"\n";