mikeward61 has asked for the wisdom of the Perl Monks concerning the following question:

We create files on our Linux servers that are NDM'd and processed on our mainframes. We need the ability to create a trailer record that contains a packed field indicating the number of records that should be in the file (i.e. 240 records would be x'0000240C'). Is this possible in Perl?