1# $FreeBSD$ 2# Although POSIX leaves the result of expanding ${#@} and ${#*} unspecified, 3# make sure it is at least numeric. 4 5set -- bb cc ddd 6set -f 7lengths=${#*}${#@}"${#*}${#@}"$(echo ${#*}${#@}"${#*}${#@}") 8IFS= 9lengths=$lengths${#*}${#@}"${#*}${#@}"$(echo ${#*}${#@}"${#*}${#@}") 10case $lengths in 11*[!0-9]*) 12 printf 'bad: %s\n' "$lengths" 13 exit 3 ;; 14????????????????*) ;; 15*) 16 printf 'too short: %s\n' "$lengths" 17 exit 3 ;; 18esac 19