Что будет выходить из кода, используя equals operator < /p>
package Test;
>>Class a is created
class A
{
int i;
int j;
A()
{
i=1;
j=2;
}
}
>> test 7 is a class
public class test7 {
public static void main(String[] args) {
>> obj1 andobj2 are objects
A obj1 =new A();*object created*
A obj2 = new A();
System.out.println(obj1.equals(obj2));
}
}
Подробнее здесь: https://stackoverflow.com/questions/610 ... s-operator