From 9dea477ffaf72d4bb7b3cab9cd9168ea1b5e7bbd Mon Sep 17 00:00:00 2001 From: Donaut Date: Sun, 7 Aug 2022 02:23:45 +0200 Subject: [PATCH] Smal inefficiency. If we found an integer with the same value we should exit the for loop by calling break; instead of continue; --- src/CromulentBisgetti.ContainerPacking/Algorithms/EB_AFIT.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/CromulentBisgetti.ContainerPacking/Algorithms/EB_AFIT.cs b/src/CromulentBisgetti.ContainerPacking/Algorithms/EB_AFIT.cs index c10292c..a0369ea 100644 --- a/src/CromulentBisgetti.ContainerPacking/Algorithms/EB_AFIT.cs +++ b/src/CromulentBisgetti.ContainerPacking/Algorithms/EB_AFIT.cs @@ -619,7 +619,7 @@ private void ListCanditLayers() if (exdim == layers[k].LayerDim) { same = true; - continue; + break; } } @@ -1219,4 +1219,4 @@ private class ScrapPad #endregion Private Classes } -} \ No newline at end of file +}