From bd6b78605d7b4757948b071d653e61a3ff4d802e Mon Sep 17 00:00:00 2001 From: platoff aeeee Date: Mon, 25 Dec 2023 11:04:35 +0400 Subject: [PATCH] =?UTF-8?q?=D0=93=D0=BE=D1=82=D0=BE=D0=B2=D0=B0=D1=8F=208?= =?UTF-8?q?=20=D0=BB=D0=B0=D0=B1=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Tank/Tank/ObjectComparable.cs | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 Tank/Tank/ObjectComparable.cs diff --git a/Tank/Tank/ObjectComparable.cs b/Tank/Tank/ObjectComparable.cs new file mode 100644 index 0000000..0ec5799 --- /dev/null +++ b/Tank/Tank/ObjectComparable.cs @@ -0,0 +1,25 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Tank.DrawingObjects; +using Tank.Generics; + +namespace Tank +{ + internal class ObjectComparable : IComparer + { + public int Compare(TanksGenericStorage? x, TanksGenericStorage? y) { + if (x == null) + { + return 1; + } + if (y == null) + { + return 1; + } + return 0; + } + } +}