> Thanks, this does work for addition and subtraction.  The problem I
> run into is when I try to divide and return a decimal.
> For example:
> !echo '(17/32)*1000' | bc    #returns 0;  The problem is that the  
> scale variable in bc must be set to a number other than zero in order  
> to display the calculation correctly.

Two ways to do this:

:!echo 'scale=2;(17/32)*1000' | bc


or (better yet)

:!echo '(17/32)*1000' | bc -l

HTH

-- 
cu
  --== Jerri ==--
Homepage: http://www.jerri.de/   ICQ: 54160208
Public PGP Key: http://www.jerri.de/jerris_public_key.asc

Attachment: signature.asc
Description: Digital signature

Reply via email to