bug-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: initialization of float arrays


From: Gabriel Zachmann
Subject: Re: initialization of float arrays
Date: 6 Sep 2001 20:25:26 GMT
User-agent: slrn/0.9.7.0 (Linux)

On 6 Sep 2001 14:54:49 GMT, André Pönitz <address@hidden> wrote:
>  Gabriel Zachmann <address@hidden> wrote:
>  > This seems like a bug to me.
>  
>  Given the limited precision of a float and the fact that base 10 fractions
>  do not necessarily have a nice short base 2 form, what did you expect?

in the case I posted, 
I expected the last 3 values to be 1.01 (= 2/2+0.1),
not some value that looks like uninitialized ...

Gab.


-- 
/---------------------------------------------------------------------\
| And what if all of animated nature                                  |
| Be but organic Harps diversely fram'd,                              |
| That tremble into thought, as o'er them sweeps                      |
| Plastic and vast, one intellectual breeze,                          |
| At once the Soul of each, and God of all?  (Samuel Taylor Coleridge)|
|                                                                     |
| address@hidden                 __@/'  address@hidden |
| web.informatik.uni-bonn.de/~zach    __@/'   www.gabrielzachmann.org |
\---------------------------------------------------------------------/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]