From 97d54464257644f086b01b590ef82946ee052e80 Mon Sep 17 00:00:00 2001 From: Samuel Lord <9904667+NodeMixaholic@users.noreply.github.com> Date: Sat, 27 Jan 2024 16:28:02 -0600 Subject: [PATCH] Update index.js --- index.js | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/index.js b/index.js index 9e4e76d..1373404 100644 --- a/index.js +++ b/index.js @@ -13,16 +13,12 @@ function fisqrt(number) { return y; } -//manual sqrt -function msqrt(number) { - for (var i = 0; i * i <= number; i++) { - if (i * i === number) - return i; - } - return number; +//square +function sq(n1, n2) { + return n1 * n2; } -//square -function sq(number) { +//square self +function sqs(number) { return number * number; }