I expect this is a fundamental question and therefore should be easy
to answer?! I have a script that compares real numbers that are typed
in by the user but I can't seem to do greater than/less than type
comparisons correctly unless the values are integers. My script looks
read lipid?" lip I/D : "
read lipod?" lip O/D : "
#DIMENSION RELATIVE CONTINUITY CHECK 1
#if expr $lipod \<= $lipid >/dev/null #thinks 9.1 is greater than or
equal to 10.1
if [ $lipod -le $lipid ] #thinks 10.1 is greater than or equal to
echo " Lip O/D is less than or equal to your lip I/D"
I'm running on IRIX 6.5.1 if that's of any relevance.
Comments, criticism, and suggestions for improvements are welcome.