QuestionQ68

VerifiedShells y scripts

What information does the echo $? command display?

Explanation

In a shell, $? contains the exit status of the command executed immediately before the current command. Therefore, echo $? prints that preceding command’s exit value.

Community Discussion

No comments yet. Be the first to start the discussion!