From 6e6bf69bdf71e08a44c4463baf9dc88df4acc74b Mon Sep 17 00:00:00 2001 From: Immanuel Alvaro Bhirawa Date: Sat, 6 May 2023 20:01:25 +1000 Subject: [PATCH] yes Signed-off-by: Immanuel Alvaro Bhirawa --- src/comp1110/ass2/State.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/comp1110/ass2/State.java b/src/comp1110/ass2/State.java index b1d364f..a7b3558 100644 --- a/src/comp1110/ass2/State.java +++ b/src/comp1110/ass2/State.java @@ -594,7 +594,7 @@ public class State { recurssionLink(allCoords, current, longest, now); // if the score is bigger, update the Set - if(scoreForLink(current, islands) > scoreForLink(longest,islands)) { + if(helperScoreForLink(current, islands) > helperScoreForLink(longest,islands)) { longest.clear(); longest.addAll(current); } @@ -615,7 +615,7 @@ public class State { } } - public static int scoreForLink(Set longestLink, Island[] islands) { + public static int helperScoreForLink(Set longestLink, Island[] islands) { int numOfIslands = 0; outerLoop: