From 57d134fe34601615300ec6c83915d4c1b8068583 Mon Sep 17 00:00:00 2001 From: worriedape <144045807+worriedape@users.noreply.github.com> Date: Tue, 10 Dec 2024 16:38:10 -0600 Subject: [PATCH] Add formulas for both conversion functions --- 07_tempConversion/tempConversion.js | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/07_tempConversion/tempConversion.js b/07_tempConversion/tempConversion.js index 14153e0a6b1..bccda3eed23 100644 --- a/07_tempConversion/tempConversion.js +++ b/07_tempConversion/tempConversion.js @@ -1,7 +1,17 @@ -const convertToCelsius = function() { +const convertToCelsius = function(fahre) { + +let convert = ((fahre - 32) * 5/9); + +return convert.toFixed(1) + }; -const convertToFahrenheit = function() { +const convertToFahrenheit = function(celsius) { + +let convert = ((celsius - 32) * 9 / 5); + +return convert.toFixed(1); + }; // Do not edit below this line