in reply to Converting Perl code to C++ code

The Monastery is -- among other things -- a site where willing Monks will help anyone who wishes to apply effort to learning Perl. Your question suggests this is not your intent.

Thus, while someone may indeed offer a (start on a) translation, you should also be aware that this is not code-a-matic. Perhaps you should post an offer (NOT here; perhaps at http://jobs.perl.org/ ) to pay someone for this work.

Or, perhaps you meant to post at a C++ site?