I am very new to programming. I have the following code:
float f = 18.45f;
this works great. If I changed this to:
float f = 18.45;
java says this as an error:
error: possible loss of precision
But its optional in terms of double . But in long again I ran into the same problem.
Why does Java make me do this, but not in the case of double ?
sriram
source share