Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Reverse a String

const reverse = str => str.split('').reverse().join('');

reverse('hello world');     
// Result: 'dlrow olleh'
Source by dev.to #
 
PREVIOUS NEXT
Tagged: #Reverse #String
ADD COMMENT
Topic
Name
1+3 =