The Army Battle problem gives me this error when testing:
army_1 = Army()
army_2 = Army()
army_1.add_units(Warrior, 20)
army_2.add_units(Warrior, 21)
battle = Battle()
battle.fight(army_1, army_2)
Your result:
false
Right result:
true
The problem states that "fight()" should return "True" when the first army is stronger, "False" otherwise. In this case, the test expects my function to return that the first army is stronger, when it's obvious that the second army is stronger, because it contains one more of the the exact same type of warrior.
From: https://py.checkio.org/mission/army-battles/solve/
HTTP_USER_AGENT:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.102 Safari/537.36
Created at: 2019/05/07 22:43; Updated at: 2019/05/08 11:36
The question is resolved.