#C5466. Reverse Each Word

    ID: 49118 Type: Default 1000ms 256MiB

Reverse Each Word

Reverse Each Word

Given a string containing a series of space-separated words, write a program to reverse each word individually while preserving the order of the words.

For example, if the input is "This is a test", the output should be "sihT si a tset".

Note that punctuation attached to a word is reversed along with the letters.

inputFormat

The input consists of a single line from standard input containing a series of words separated by spaces. The input may include punctuation and extra spaces.

outputFormat

Output a single line to standard output where each word from the input has been reversed individually, preserving their original order.## sample

Hello
olleH

</p>