diff --git a/Tank/Tank.iml b/Tank/Tank.iml index 7b1a111..af3c693 100644 --- a/Tank/Tank.iml +++ b/Tank/Tank.iml @@ -1,6 +1,6 @@ - + diff --git a/Tank/src/SetGeneric.java b/Tank/src/SetGeneric.java index f091eec..6671cee 100644 --- a/Tank/src/SetGeneric.java +++ b/Tank/src/SetGeneric.java @@ -24,7 +24,7 @@ public class SetGeneric { public boolean Insert(T tank, int position) { // Проверка позиции - if (position < 0 || position >= _maxCount) + if (position < 0 || position >= Count()) throw new TankNotFoundException(position); if (_places.size() >= _maxCount)