Untitled
unknown
plain_text
3 years ago
285 B
6
Indexable
#!/bin/bash if [[ -z "$3" ]]; then op=$ARITHMETIC_OP else op=$3 fi if [[ $op == "add" ]]; then echo $(($1 + $2)) elif [[ $op == "sub" ]]; then echo $(($1 - $2)) elif [[ $op == "mul" ]]; then echo $(($1 * $2)) elif [[ $op == 'div' ]]; then echo $(($1 / $2)) fi
Editor is loading...