I must be missing something. You have 2 subroutines and nothing that calls either one in the main code block? As is, this does nothing.
On the other hand, I like the obfu concept of using the same variable in different ways by chainging the capitalization.....
-Kevin
my $a='62696c6c77667269656e6440676d61696c2e636f6d';
while ($a=~m/(^.{2})/s)
{print unpack('A',pack('H*',"$1"));$a=~s/^.{2}//s;}