added answers

This commit is contained in:
Jared Ramon Elizan 2022-07-16 10:32:21 +08:00
parent e306883107
commit 19eb17bce0
1 changed files with 8 additions and 4 deletions

View File

@ -1,9 +1,13 @@
const ftoc = function() {
const ftoc = function(fahr) {
//let converted = parseInt(fahr);
let converted = (fahr - 32) * 5/9;
return Math.round(converted * 10) / 10;
};
const ctof = function() {
const ctof = function(cel) {
//let converted = parseInt(cel);
let converted = (cel * 9/5) + 32;
return Math.round(converted * 10) / 10;
};
// Do not edit below this line