[ILUG-BOM] bc and bash scripting woes

Philip S Tellis philip.tellis@[EMAIL-PROTECTED]
Tue Jan 15 19:38:03 IST 2002


On Tue, 15 Jan 2002, Parvez Lanewala wrote:

> for i in `seq 0 10`;
> do
>     SUM=`echo $SUM+${ARR[$i]}|bc`
> done

SUM=$(($SUM + ${ARR[$i]}))

Philip

-- 
I do not find in orthodox Christianity one redeeming feature.
- Thomas Jefferson




More information about the Linuxers mailing list