X-Recipient: archive-cygwin@delorie.com
X-Spam-Check-By: sourceware.org
Date: Thu, 27 Sep 2007 17:01:49 +0100
From: Owen Rees <owen.rees@hp.com>
To: cygwin@cygwin.com
Subject: Re: strange behavior with perl v 5.8.8
Message-ID: <6F610F274679310E33C07DE5@orees.hpl.hp.com>
In-Reply-To: <5abc24640709270814j5148c43ejbfe46f022fd6ad1b@mail.gmail.com>
References: <5abc24640709270814j5148c43ejbfe46f022fd6ad1b@mail.gmail.com>
X-Mailer: Mulberry/4.0.6 (Linux/x86)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

--On Thursday, September 27, 2007 11:14:09 AM -0400 Andrew Louie wrote:

> when incrementing by 0.1 i get a strange behavior where at some
> arbitrary  number, it will append 0.9999999999 to the end of the
> number.

This is rounding error and applies to all computer systems and all 
programming languages that use fixed size number representations. It can be 
fatal - for example see 
<http://www.ima.umn.edu/~arnold/disasters/patriot.html>.

-- 
Owen Rees; speaking personally, and not on behalf of HP.
========================================================
Hewlett-Packard Limited.   Registered No: 690597 England
Registered Office:  Cain Road, Bracknell, Berks RG12 1HN

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

