Task

 verify the version/revision of your currently running (compiler/interpreter/byte-compiler/runtime environment/whatever your language uses) and exit if it is too old.
 check whether the variable "bloop" exists and whether the math-function "abs()" is available and if yes compute abs(bloop).


Extra credit

 Report the number of integer variables in global scope, and their sum.


case ${.sh.version} in
    *93[[:alpha:]]+*) :;; #this appears to be ksh93, we're OK
    *)  echo "version appears to be too old"
        exit              # otherwise, bail out
        ;;
esac
 
if [[ -z ${bloop+bloop has a value} ]]; then
    print "no bloop variable"
elsif (( abs(1) )); then
    print -- $(( abs(bloop) ))
fi
 
typeset -a int_vars
set | while IFS='=' read -r var value; do
    if [[ $value == +([[:digit:]]) ]]; then
        int_vars[n++]=$var
        let sum += $value
    fi
done
print "${int_vars[*]}"
print -- $sum