SUM=0 NUMBER1=`cat $FILE1` for m in $NUMBER1 do SUM=`echo "scale=4; $SUM * $m" |bc` done
Not exactly right, but you get the jist of it. Obviously this won't work:
SUM=0 NUMBER1=`cat $FILE1` NUMBER2=`cat $FILE2` for m in $NUMBER1 and n in $NUMBER2 do SUM=`echo "scale=4; $m * $n" |bc` done
Thanks for any help you can provide, let me know if you need more info.
Michael French - : send the line "unsubscribe linux-admin" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html