Path: utzoo!utgpu!watserv1!watmath!att!rutgers!cs.utexas.edu!uunet!iconsys!mday From: mday@iconsys (Matt Day) Newsgroups: comp.unix.shell Subject: Re: bourne shell query Message-ID: <75@iconsys> Date: 1 Sep 90 23:44:10 GMT References: <26DC6447.15922@maccs.dcss.mcmaster.ca> <8446@orca.wv.tek.com> Organization: Sanyo/ICON International, Orem, UT Lines: 11 In article scott@tab00.larc.nasa.gov (Scott Yelich) writes: >As a side question, does ANYONE have any bourne shell routines which do >math... reasonably effeciently? (For numbers > 1000?) For the Bourne shell, the most efficient way to do math is to use the "expr" program. It doesn't support floating point, but it doesn't have any trouble with numbers larger than 1000. If you have a shell script that needs to do a lot of math, I suggest you use the C shell built in math operators; it's much faster (or perl, of course). -- - Matthew T. Day, Sanyo/ICON, mday@iconsys.icon.com || uunet!iconsys!mday