сравнение методов работает. проверял. Но видимо какое-то условие не выполняется и я не могу найти какое. есть мысли?
package com.javarush.task.task05.task0502;
/*
Реализовать метод fight
*/
public class Cat {
public int age;
public int weight;
public int strength;
public Cat() {
}
public boolean fight(Cat anotherCat) {
//напишите тут ваш код
int score = 0;
if (this.age >= anotherCat.age){
score += 1;
}
if (this.weight >= anotherCat.weight){
score += 1;
}
if (this.strength >= anotherCat.strength) {
score += 1;
}
return score > 1;
}
public static void main(String[] args) {
}
}