-
Bug
-
Resolution: Not an Issue
-
P4
-
None
-
8
-
x86_64
-
windows_10
ADDITIONAL SYSTEM INFORMATION :
windows 10
A DESCRIPTION OF THE PROBLEM :
Please run below code in java 8 :
public static void main(String[] args)
{
System.out.println(2.0 + 0.9999);
}
The sum was expected to be 2.9999 but found 2.9999000000000002
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Just run this :
public static void main(String[] args)
{
System.out.println(2.0 + 0.9999);
}
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
2.9999
ACTUAL -
2.9999000000000002
---------- BEGIN SOURCE ----------
class Test
{
public static void main(String[] args)
{
System.out.println(2.0 + 0.9999);
}
}
---------- END SOURCE ----------
FREQUENCY : always
windows 10
A DESCRIPTION OF THE PROBLEM :
Please run below code in java 8 :
public static void main(String[] args)
{
System.out.println(2.0 + 0.9999);
}
The sum was expected to be 2.9999 but found 2.9999000000000002
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Just run this :
public static void main(String[] args)
{
System.out.println(2.0 + 0.9999);
}
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
2.9999
ACTUAL -
2.9999000000000002
---------- BEGIN SOURCE ----------
class Test
{
public static void main(String[] args)
{
System.out.println(2.0 + 0.9999);
}
}
---------- END SOURCE ----------
FREQUENCY : always
- duplicates
-
JDK-8300408 5+0.56=5.5600000000000005
- Closed