C:\test>p1 use Devel::Peek;; sub toPascal{ return chr( length $_[0] ) . $_[0] };; Dump toPascal( 'x' x $_ ) for 255, 256;; SV = PV(0x28d280) at 0x3c599e0 REFCNT = 1 FLAGS = (TEMP,POK,pPOK) PV = 0x3cb28f8 "\377xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx CUR = 256 LEN = 264 SV = PV(0x3c3aa30) at 0x3c599c8 REFCNT = 1 FLAGS = (TEMP,POK,pPOK,UTF8) PV = 0x3cb2a28 "\304\200xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"] CUR = 258 LEN = 264