Article View: comp.unix.shell
Article #991Re: bourne shell query
From: Matt Day
Date: Sat, 01 Sep 1990 23:44
Date: Sat, 01 Sep 1990 23:44
11 lines
1070 bytes
1070 bytes
In article <SCOTT.90Aug30124930@tab00.larc.nasa.gov> 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
Technical Details
Message-ID:
<75@iconsys>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!watserv1!watmath!att!rutgers!cs.utexas.edu!uunet!iconsys!mdayReferences:
<26DC6447.15922@maccs.dcss.mcmaster.ca> <8446@orca.wv.tek.com> <SCOTT.90Aug30124930@tab00.larc.nasa.gov>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!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> <SCOTT.90Aug30124930@tab00.larc.nasa.gov> Organization: Sanyo/ICON International, Orem, UT Lines: 11