SCJP1.6,SCWCD1.5
SCJP 6.0
SCJP1.6,SCWCD1.5
narendra wrote:It does.
SCJP1.6,SCWCD1.5
narendra wrote:sir i have written both the codes one compliles and one give compilation error..
SCJP1.6,SCWCD1.5
SCJP1.6,SCWCD1.5
SCJP1.6,SCWCD1.5
SCJP1.6,SCWCD1.5
narendra bhattacharya wrote:sir java 1.6 sun microsystem..
SCJP1.6,SCWCD1.5
SCJP 6.0
if the operands of an equality operator are both of numeric type, or one is of numeric type and the other is convertible (§5.1.8) to numeric type, binary numeric promotion is performed on the operands (§5.6.2). If the promoted type of the operands is int or long, then an integer equality test is performed; if the promoted type is float or double, then a floating-point equality test is performed.
Note that binary numeric promotion performs value set conversion (§5.1.13) and unboxing conversion (§5.1.8). Comparison is carried out accurately on floating-point values, no matter what value sets their representing values were drawn from.
SCJP 6.0
Passed: SCJP 6 (90%), SCJD 6
Other: Spring training, extensive Swing experience
SCJP-6.0 OCPJWCD-5.0
John McParland wrote:
And looking at the boxing rules;
You CANNOT widen from one wrapper type to another (IS-A fails.)
You CANNOT widen then box. (An int can't become a Long.)
You can box and then widen. (An int can become an Integer then a Number.)
SCJP-6.0 OCPJWCD-5.0
SCJP1.6,SCWCD1.5
The first and the third rule listed here contradict each other.. isn't??
Passed: SCJP 6 (90%), SCJD 6
Other: Spring training, extensive Swing experience
SCJP1.6,SCWCD1.5
I knew I would regret that burrito. But this tiny ad has never caused regrets:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
|