code snippet... boolean[] b1 = new boolean[2]; boolean[] b2 = {true , false}; System.out.println( "" + (b1[0] == b2[0]) + ", "+ (b1[1] == b2[1]) ); b1's elements are initialised to false and false...anyway, it seems that false,true is printed out...what bothers me is that == seems to be behaving like a Wrapper class equals() method here?
giddee up
Maulin Vasavada
Ranch Hand
Joined: Nov 04, 2001
Posts: 1865
posted
0
hi jasper, why it bothers u? b1[0] , b1[1] , b2[0], b2[1] are simple boolean variables and == works same as normal == works for any other primitive data type... whats so big deal here? i don't understand your point. regards maulin.