Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: Understanding $?

by kennethk (Abbot)
on Mar 06, 2013 at 22:44 UTC ( #1022112=note: print w/ replies, xml ) Need Help??


in reply to Understanding $?

The docs: $?.

$? is assigned a value in the background on the line @output = `$cmd`;, independent of what you do. The value itself depends on the status code returned from (I presume) iwodstart.

If you have multiple commands in $cmd or any i/o redirects (which you do), then the child process is actually a shell around your command set, and the return value in $? is the returned status code from the shell.


#11929 First ask yourself `How would I do this without a computer?' Then have the computer do it the same way.


Comment on Re: Understanding $?
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1022112]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (12)
As of 2015-07-06 15:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (77 votes), past polls