Hi,
I think you asked the diference between the =(assignment operator)and the ==(boolean equality operator). = is used to say that the left most operand to get the value of the rigth most one.
eg:- int x=1;
int y=2;
int x=y;
this code makes the integer x to get the value of y.Now x is 2.
Now lets get to the ==. This is used to check the equality.For primitives it checks the value. For object references it checks the referenced object.
eg:- int x=1;
int y=1;
if(x==y)
System.out.print("x and y are equal");
//here it prints "x and y are equal"
I think you can understand this explanation of mine.
Thanks.
[ December 19, 2004: Message edited by: Rajith Vidanaarachchi ]