Passing arguments to scripts (both `bat` and `bash`)

Windows script .bat

//windows-script.bat
set firstArgument=%1%
set secondArgument=%2%

echo You passed first %firstArgument% and second %secondArgument%

Call it as

.\windows-script.bat "little donald" "had a farm"

Unix script .bash

//unix-script.bash
#!/bin/sh
firstArgument=$1
secondArgument=$2

echo You passed first $firstArgument and second $secondArgument

# to give a default value to the argument
arg="${1:-DEFAULT_VALUE}"

Call it as

bash unix-script.bash "little donald" "had a farm"