#C13925. Reverse a String
Reverse a String
Reverse a String
You are given a string s
. Your task is to output the reverse of the given string.
The reversal of a string is defined as the characters of the string in reverse order. Mathematically, if the string is represented as \( s = s_1s_2...s_n \), then its reverse is \( s_n...s_2s_1 \).
Note: The input is provided through the standard input and the output should be printed to standard output.
inputFormat
The input consists of a single line containing the string s
to be reversed. The string may include spaces, punctuation, or any other characters.
Input is to be read from stdin
.
outputFormat
Output the reversed string. The output should be printed to stdout
.
Hello, World!
!dlroW ,olleH