Bash
is_num() in Bash: Check if a Value Is a Number
Check that input is a whole number, a signed integer or a decimal before doing arithmetic, and avoid the octal, empty-string and injection problems in (( )).
Archive
Check that input is a whole number, a signed integer or a decimal before doing arithmetic, and avoid the octal, empty-string and injection problems in (( )).