Issue
I am using bash shell on linux and want to use more than 10 parameters in shell script
id='dv4'>
Solution
Use curly braces to set them off:
echo "${10}"
Any positional parameter can be saved in a variable to document its use and make later statements more readable:
city_name=${10}
If fewer parameters are passed then the value at the later positions will be unset.
You can also iterate over the positional parameters like this:
for arg
or
for arg in "$@"
or
while (( $# > 0 )) # or [ $# -gt 0 ]
do
echo "$1"
shift
done
Answered By - Dennis Williamson Answer Checked By - Cary Denson (WPSolving Admin)