Expr and $(( ))
Appearance
General
- Use expr to do math
- x = `expr $x + 1` or use this syntax too x=$(expr $1 + 1)
- Can't you just do x = $x + 1???
- x = `expr $x + 1` or use this syntax too x=$(expr $1 + 1)
- In modern scripts expr is replaced with $((...)