Loading...
Processing Forum
Recent Topics
All Forums
Screen name:
iupdiesing
iupdiesing's Profile
1
Posts
0
Responses
0
Followers
Activity Trend
Last 30 days
Last 30 days
Date Interval
From Date :
To Date :
Go
Loading Chart...
Posts
Responses
PM
Show:
All
Discussions
Questions
Expanded view
List view
Private Message
float summation bug !(?)
[1 Reply]
31-Jul-2013 04:01 AM
Forum:
Programming Questions
the following program
float i, x = 0.9;
for (i = 0; i < 1; i += 0.1) {print(i);print(";");println(x += 0.1);}
shows this console output:
0.0;1.0
0.1;1.1
0.2;1.2
0.3;1.3000001
0.4;1.4000001
0.5;1.5000001
0.6;1.6000001
0.70000005;1.7000002
0.8000001;1.8000002
0.9000001;1.9000002
Where do the "0.000000X" values come from?
«Prev
Next »
Moderate user : iupdiesing
Forum