Home
Topics
Practice
Roadmap
DSA Tracker
Code Editor
Tech Blogs
More
Sign in
Get started
Loading question...
Feedback
Reverse a String
Easy
00:00
0 users online
Share
Description
Solution
Submissions
Discussion
Write a function that takes a string and returns it reversed.
Sample Input:
"hello"
Sample Output:
"olleh"
Hints
Hint 1
You can split the string into an array of characters
Hint 2
Reverse the array and join it back
Hint 3
Consider using split(), reverse(), and join() methods
Code Editor
Reset
Run
Save
Loading...