What's the differences between system and backticks and pipes in Perl? -


Pearl supports three methods of running an external program (which I know):

< Code> System :

  System program list  

As:

  The system "abc" ;  

Backticks as:

  `ABC`;  

Run it through a pipe like:

  open ABC, "abc |";  

What are the differences between them?

  • It is that I know it:

    1. You can use backtakes and pipes to easily get the output of the command.
    2. Is this (more in future edits?)
  • "post-text" itemprop = "text">
    • System (): Runs the command and returns the exit status of the command
    • The backattes: runs the command and output
    • the pipe Gives command: runs the command and allows you to use as a handle

    In addition to the program execution of backdone, restore STDOOT in a variable Deshit, and the system sends Steediooti your main program.


    Comments