Reverse a string

Write a simple code to reverse a string. INPUT: "HELLO WORLD" OUTPUT: "DLROW OLLEH" The logic to reverse a string is simple, swap the first character with last character, the second character with the second-last character and so on… Take two variables low and high to hold the indices of first and last element, increment […]
 •  0 comments  •  flag
Share on Twitter
Published on March 13, 2019 11:14
No comments have been added yet.