float widens for int,short,byte,char & float ofcourse.
how does it widen for long?
the output for the above...
inside float param
inside float param
inside float param
inside float param
inside float param
inside float param
may I know how it does?
Thanks
regards
samura
MooN
SCJP 5.0 | SCWCD 1.4
But i don't understand why it is chosen also for a double(wich is wide than a float). Do any one has the reason ?
But in that code doesn�t have the line obj.m1(d);
But if you put in then the result is "inside double param".
SCJP 5.0 | SCWCD 1.4
This because "between two methods that accept float or double, float will be chosen".
SCJP 5.0 | SCWCD 1.4
...between two methods that accept float or double, float will be chosen
SCJP 5.0 | SCWCD 1.4
MooN