Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

reverse string

function reverseString(str) {
  let reversedStr = "";
  for (let i = str.length - 1; i >= 0; i--) {
    reversedStr += str[i];
  }
  return reversedStr;
}
Source by forum.freecodecamp.org #
 
PREVIOUS NEXT
Tagged: #reverse #string
ADD COMMENT
Topic
Name
3+4 =