When I run the following code, I get an error:
double i = 1;
double pound;
System.out.println("Kilograms\t Pounds");
for(i = 1; i<199; i+=2){
pound = i * 2.2;
System.out.println(i + "\t\t" + pound + "\n");
}
The error:
Kilograms Pounds 1.0 2.2 3.0 6.6000000005 5.0 11.0 7.0 15.400000002
As Peter said, this is due to the imprecision of floating point numbers. To fix it, use printf, like this:
See here or here for more information on how to use printf.