On Thu, Aug 05, 1999 at 02:53:02PM +0200, E.L. Meijer (Eric) wrote: > Says Mike: > > bash shells can do: > > > > let a=$b+$c*$d > > let a=($b+$c)*$d > > > > but if you want to ensure compatibility with Bourne shells like > > ash, you should stick to: > > > > a=$(($b+$c*$d)) > > a=$((($b+$c)*$d)) > > but if you want to ensure compatibility with Bourne shells like > the Bourne shell :), you should stick to > > a=`expr $b + $c \* $d` > a=`expr \( $b + $c \) \* $d` > > to complicate things, the spaces in the expression after `expr' are > required. >
I stand corrected :) It's been a LONG time since I've use the authentic one-and-only Bourne shell. How many Bourne shell clones do we have floating around here these days? Mike [Private mail welcome, but no need to CC: me on list replies.] -- Michael Merten ---> E-Mail: [EMAIL PROTECTED] ---> NRA Life Member -- http://www.nra.org ---> Debian GNU/Linux Fan -- http://www.debian.org ---> CenLA-LUG Founder -- http://www.angelfire.com/la2/cenlalug -- Rincewind had generally been considered by his tutors to be a natural wizard in the same way that fish are natural mountaineers. He probably would have been thrown out of Unseen University anyway-- he couldn't remember spells and smoking made him feel ill. -- Terry Pratchett, "The Light Fantastic" -- This signature was automatically generated with Signify v1.06. For this and other cool products, check out http://www.debian.org/.