Multiple choice unix

Which symbol is used to separate more than one command in the same command line?

  1. $
  2. #

  3. :

  4. ;

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

The semicolon (;) is used to separate multiple commands on a single line in UNIX shells, allowing sequential execution. $ is for variables, # for comments, : has other uses.

AI explanation

The semicolon ; is the standard shell command separator, letting you place multiple independent commands on one line where each runs in sequence regardless of the previous command's exit status. $ is used for variable expansion, # starts a comment, and : is a shell no-op builtin — none of them separate sequential commands.