From 2ae00a97dc575dea1f7704e131ab4a509d1c91eb Mon Sep 17 00:00:00 2001 From: YATIN KATHURIA <47096348+Yatin-kathuria@users.noreply.github.com> Date: Tue, 23 Nov 2021 11:34:26 +0530 Subject: [PATCH] merge: add description (#843) --- Navigation/Haversine.js | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/Navigation/Haversine.js b/Navigation/Haversine.js index 8ad872d7f..7a6254a9d 100644 --- a/Navigation/Haversine.js +++ b/Navigation/Haversine.js @@ -1,10 +1,12 @@ -/* - Calculate the distance between two coordinates using the haversine formula - More about: https://pt.wikipedia.org/wiki/F%C3%B3rmula_de_Haversine - @Param {number} latitude1 - @Param {number} latitude2 - @Param {number} longitude1 - @Param {number} longitude2 +/** + * @function HaversineDistance + * @description Calculate the distance between two coordinates using the haversine formula + * @param {Integer} latitude1 - The input integer + * @param {Integer} latitude2 - The input integer + * @param {Integer} longitude1 - The input integer + * @param {Integer} longitude2 - The input integer + * @return {Integer} Haversine Distance. + * @see [Haversine_Distance](https://pt.wikipedia.org/wiki/F%C3%B3rmula_de_Haversine) */ const haversineDistance = (latitude1 = 0, longitude1 = 0, latitude2 = 0, longitude2 = 0) => { validateLatOrLong(latitude1)