From 1a5e6e235a7a73a8b718f6401f2c84db414501ee Mon Sep 17 00:00:00 2001 From: keithbored3310 <108907420+keithbored3310@users.noreply.github.com> Date: Tue, 30 Aug 2022 22:10:56 +0800 Subject: [PATCH] Delete Manhattan Distance --- src/algorithms/math/Manhattan Distance | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 src/algorithms/math/Manhattan Distance diff --git a/src/algorithms/math/Manhattan Distance b/src/algorithms/math/Manhattan Distance deleted file mode 100644 index 6ce947a59c..0000000000 --- a/src/algorithms/math/Manhattan Distance +++ /dev/null @@ -1,18 +0,0 @@ -//This function is calculate the manhattan distance -@param x -@param y -@return {SumOhManhattanDistance} - -export default function manhattanDistance(x, y){ - -let SumOfManhattanDistance = 0; - -for (let i = 0; i < x.length; i++){ - for (lei j= 0; j < x[i].length ; j++){ - //Compute the result of the Manhattan Distance - SumOfManhattanDistance += (Math.abs(x[i] -x[j])+Math.abs(y[i] - y[j])); - } -} -//Send the result back to the main function -return SumOfManhattanDistance; -}