RosettaCodeData/Task/Increment-a-numerical-string/UNIX-Shell/increment-a-numerical-string-1.sh

5 lines
165 B
Bash
Raw Permalink Normal View History

2013-04-10 22:43:41 -07:00
# All variables are strings within the shell
# Although num look like a number, it is in fact a numerical string
num=5
num=`expr $num + 1` # Increment the number