Menu
Coddy logo textTech

1. Reverse a String

Lesson 2 of 31 in Coddy's 30 Days of Logic Building in Javascript course.

challenge icon

Challenge

Easy

Write a function that takes a string as input and returns the string reversed.

 

  • Input: <strong>"Hello"</strong>
  • Output: <strong>"olleH"</strong>

Try it yourself

function reverseString(str) {
    // write your code below
   
}

All lessons in 30 Days of Logic Building in Javascript