in reply to passing a parameter to an outside program

The child needs to print the data out to standard input (which the parent must have ready to capture) or to a temporary file (whose name the parent might have passed as an argument).

The simple case where the parent waits for the child to complete can be written as:

parent ------ $result = `child.pl`; child ----- print($result);