From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27585 invoked from network); 10 Oct 2001 08:36:42 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 10 Oct 2001 08:36:42 -0000 Received: (qmail 13533 invoked by alias); 10 Oct 2001 08:36:06 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 4360 Received: (qmail 13519 invoked from network); 10 Oct 2001 08:36:04 -0000 Date: Wed, 10 Oct 2001 01:33:24 +0200 From: Bruno Bonfils To: ZSH Users Subject: question about float variables Message-ID: <20011010013324.A9741@debian-fr.org> Mail-Followup-To: Bruno Bonfils , ZSH Users Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="+QahgC5+KEYLbs62" Content-Disposition: inline User-Agent: Mutt/1.2.5i --+QahgC5+KEYLbs62 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable hi all, How to divide two numbers ? I try this : float var1=3D0.0 var1=3D$((2.4 + 1.4)) echo $var1 return 3.800000000e+00 good !! but float var1=3D0.0 var1=3D$((3 / 2))=20 echo $var1 return 1.000000000e+00 not good ! :( and how to format the output of $var1 ? (i want a number like 95.3) Thank you very much --=20 Bruno Bonfils Admin Sys Linux http://www.darksnow.org http://www.debian-fr.org http://www.zshfr.org --+QahgC5+KEYLbs62 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: Pour information voir http://www.gnupg.org iEYEARECAAYFAjvDiUQACgkQ8dj4f/OdzPUULwCgr8HnHw5ESfujdZPzyD3MRfoj r3AAoJs6e2UkQFXDuNoLbwlf+OO4/9Co =TEn/ -----END PGP SIGNATURE----- --+QahgC5+KEYLbs62--