Multiple choice technology operating systems

The command used to move to the second input command line argument is

  1. shift $2
  2. shift + 2

  3. shift 2

  4. shift * 2

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

The shift command in shell scripting moves positional parameters left. 'shift 2' moves $3 to $1, $4 to $2, etc., effectively moving to the second command line argument. The syntax is just 'shift' followed by a number.