I am using this JAVA program where I am multiplying a double with a double and storing it in a double.
My expected output is 7.14
as per my mathematics knowledge, but I get 7.140000000000001
. I don't understand why is the 0000000000001
part is coming
public class Main
{
public static void main(String[] args) {
double a=7.0;
double b=1;
double c=a*b*1.02;
System.out.println(c);
}
}