in reply to run exe

Running external programs can be done in many ways, depending on what you actually want. system is one way. It allows you to run a program and tells you about the exit status.

If you want to capture the output of a program, see the backticks or qx() operator in perlop.

If you need to provide input to the program, you can open it via the open() command as follows:

open PAGER, "| more"; for (1..1_000) { print {PAGER} "Line $_\n"; };

If you need to both, read and write, there are IPC::Open2 and IPC::Open3.

All of these options are discussed in more detail in perlipc.