#Just use bc command for operational calculation as follows: if (( $(echo "$num1 > $num2" |bc -l) )); then … fi