The code in K&B exam
test is:
x=0;
if(x1.hashCode() != x2.hashCode()) x= x + 1;
if(x3.equals(x4) == false) x= x + 10;
if(x5.equals(x6) == true) x= x+100;
if(x7.hashCode() == x8.hashCode()) x = x + 1000;
System.out.println("x = " + x);
If the out put is " x = 1111"
it is saying that x2.equals(x1) == true
Why???
I think the answe should x5.hashCode() == x6.hashCode()
Please explain..........
SCJP 1.5, SCWCD 1.4, SCBCD 5.0, next SCDJWS...