1

I have a bash script that takes arguments for variables as the following:

V1=$1; V2=$2; V3=${3:-""};

Can someone help explain the syntax used for V3?

codeforester
  • 39,467
  • 16
  • 112
  • 140
Arzath
  • 117
  • 1
  • 11
  • 1
    Default value for `$3`. Check `man bash` – anubhava Mar 02 '18 at 17:04
  • Check the Bash Parameter Expansion section in GNU Bash Manual here: https://www.gnu.org/software/bash/manual/html_node/Shell-Parameter-Expansion.html or this post on Unix & Linux Stack Exchange: https://unix.stackexchange.com/questions/122845/using-a-b-for-variable-assignment-in-scripts – codeforester Mar 02 '18 at 17:05

0 Answers0