#C11669. Reverse a String
Reverse a String
Reverse a String
Given a string, your task is to output the string in reverse order. The string can contain letters, digits, or special symbols. This is a classic problem to test your understanding of string manipulation and input/output handling in different programming languages.
For example, if the input is "hello", the output should be "olleh". Consider various cases such as palindromic strings (e.g. "madam"), strings with numbers (e.g. "12345"), and strings with mixed characters (e.g. "a1b2c3").
Note: If any mathematical formula appears, it should be written in LaTeX format. However, this problem does not include any mathematical formulas.
inputFormat
The input consists of a single line containing a non-empty string s.
Input Format: The input is provided via stdin
.
outputFormat
Output the reversed string on a single line. The output should be written to stdout
.
hello
olleh