From 5ec534d4367f9ff02df81912996dc01a08bf00d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9D=D0=B8=D0=BA=D0=B8=D1=82=D0=B0=20=D0=91=D0=B5=D0=BB?= =?UTF-8?q?=D1=8F=D0=BD=D0=B8=D0=BD?= Date: Mon, 18 Dec 2023 01:14:18 +0400 Subject: [PATCH] =?UTF-8?q?=D0=93=D0=BE=D1=82=D0=BE=D0=B2=D0=B0=D1=8F=20?= =?UTF-8?q?=D0=BB=D0=B0=D0=B1=D0=BE=D1=80=D0=B0=D1=82=D0=BE=D1=80=D0=BD?= =?UTF-8?q?=D0=B0=D1=8F=20=D1=80=D0=B0=D0=B1=D0=BE=D1=82=D0=B0=207?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Tank/Tank.iml | 2 +- Tank/src/SetGeneric.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) 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)