What kind of strange shell syntax is hidden behind
$((40-35)) and how come it calculates a value?
$> echo $((40-35)) 5
Anything put into double parens becomes a math expression that
This is arithmetic expansion. It's supported in all POSIX shells (it didn't exist in the original Bourne shell). The syntax of arithmetic expression is mostly the same as in the C language.
You can use variables with or without a
The exact rules for deciding whether