From 83883e81ef1195a59f531c04473737fe399dc7a1 Mon Sep 17 00:00:00 2001 From: Rokas Puzonas Date: Sun, 10 Apr 2022 17:18:41 +0300 Subject: [PATCH] feat: add a couple extra comments --- L3/LD_24/Code/InOutUtils.cs | 7 +++++++ L3/LD_24/Code/Product.cs | 5 +++++ 2 files changed, 12 insertions(+) diff --git a/L3/LD_24/Code/InOutUtils.cs b/L3/LD_24/Code/InOutUtils.cs index 05a7a9d..a89120a 100644 --- a/L3/LD_24/Code/InOutUtils.cs +++ b/L3/LD_24/Code/InOutUtils.cs @@ -137,6 +137,13 @@ namespace LD_24.Code writer.WriteLine("|"); } + /// + /// Calculate the widths of each column of a table + /// + /// + /// + /// + /// private static LinkedList FindTableWidths(LinkedList> rows, string header, string[] columns) { var allWidths = new Dictionary>(); diff --git a/L3/LD_24/Code/Product.cs b/L3/LD_24/Code/Product.cs index 9a83856..0968ea7 100644 --- a/L3/LD_24/Code/Product.cs +++ b/L3/LD_24/Code/Product.cs @@ -57,6 +57,11 @@ namespace LD_24.Code return hashCode; } + /// + /// Compares 2 products by their IDs + /// + /// + /// public int CompareTo(Product other) { return ID.CompareTo(other.ID);