added answers

This commit is contained in:
Jared Ramon Elizan 2022-07-12 11:47:16 +08:00
parent 14947e81ab
commit fcf255662a
1 changed files with 6 additions and 2 deletions

View File

@ -1,5 +1,9 @@
const reverseString = function() { const reverseString = function(string) {
let reversed = "";
for(let i = string.length - 1; i >= 0; i--){
reversed+=string[i];
}
return reversed;
}; };
// Do not edit below this line // Do not edit below this line