QuestionQ51

VerifiedBasic Unix Skills

Which of the following excerpts shows a valid if condition in the Bourne shell?

Explanation

A Bourne/POSIX shell if construct has the form if compound-list; then compound-list; fi (with newlines valid as command separators). [ "$var" = "test" ] is a valid test command, and the required then and fi delimit the conditional body.

Learn more

Community Discussion

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