what is the cmd to display the last exit status in UNIX?

Answers were Sorted based on User's Feedback



what is the cmd to display the last exit status in UNIX?..

Answer / arvind kumar

echo $? will give you status og last command.

Is This Answer Correct ?    18 Yes 0 No

what is the cmd to display the last exit status in UNIX?..

Answer / siva

Try this command

$?

Is This Answer Correct ?    11 Yes 2 No

what is the cmd to display the last exit status in UNIX?..

Answer / arjun

$? it will give the status of the previous command
it will give 0(zero) last command is successful else it will
give any non-zero character.

Is This Answer Correct ?    6 Yes 0 No

what is the cmd to display the last exit status in UNIX?..

Answer / arun kumrr

echo $?

Is This Answer Correct ?    4 Yes 0 No

what is the cmd to display the last exit status in UNIX?..

Answer / kk11749

$?

Is This Answer Correct ?    4 Yes 2 No

Post New Answer

More Unix Commands Interview Questions

Write a command that will output the sorted contents of a file named in.txt and place the output in another file named out.txt, while at the same time excluding duplicate entries.

1 Answers  


Which command is used to delete all files in the current directory and all its sub-directories?

0 Answers  


Explain command to display different lines that are found when compare two files?

0 Answers  


Give Command that will move a single file called "unix.txt"

7 Answers   IBM,


what is the command to get help on a UNIX terminal?

5 Answers  


what are the different commands used to view the contents of a file?

5 Answers  


Write a command to find all of the files which have been accessed within the last 30 days.

14 Answers   Cisco,


what is the command to print last 8 lines of any text file.

10 Answers  


why unix operating system provides more security than other operating systems?

4 Answers  


Who wrote grep?

0 Answers  


can we use cat command as an editor ..???

12 Answers   TCS,


what do you understand by 'building block primitive'?

3 Answers   Infosys,


Categories