Re: korn shell help

From: phsol (phsol@UOL.COM.BR)
Date: Mon Jan 20 2003 - 18:10:19 EST


An easy script with bc

echo "First number: \c"
read a
echo "Second number: \c"
read b
bc << EOF
scale=2
$a+$b
EOF

Paulo Henrique F. Barbosa
Analista de Suporte
CPM S.A. - Líder em Integração Independente de Tecnologia
www.cpm.com.br

> Hi, Korn shell question...
>
> How you add real numbers in korn shell?
> For example ... I am adding 10.2 + 3.4 and instead of getti
ng
> 13.6 I am getting 13.
>
> I donn't have indepth knowledge of scripting. Please let me
know by posting
> an example. I don't want to use bc functionality of unix.
>
> Thanks
> -/KW
>
>
>
>
> ____________________________________________________________
_____
> Add photos to your e-mail with MSN 8. Get 2 months FREE*.
> http://join.msn.com/?page=features/featuredemail
>

---
UOL, o melhor da Internet
http://www.uol.com.br/


This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 22:16:29 EDT