// Function to reverse a string
function reverseString(str) {
return str.split('').reverse().join('');
}
// Example usage
const reversed = reverseString('Hello, World!');
console.log(reversed);
// Function to reverse a string
function reverseString(str) {
return str.split('').reverse().join('');
}
// Example usage
const reversed = reverseString('Hello, World!');
console.log(reversed);
Related
Write a program to find Reverse a String using node js |
Find the Average of an Array using node js |
How to to check if a number is a palindrome using node js |
Write a function to check if a number is prime using node js |
what is CI/CD: Github Actions? |
Find the intersection of two arrays using node js |
How to implement a Queue |
Find the longest word in a sentence using node js |