UVa 483

From Algorithmist
Jump to navigation Jump to search

483 - Word Scramble[edit]

Summary[edit]

Given a sentence output the sentence with every word reversed in place. The word must remain in the order it is read in.

Explanation[edit]

We basically need to tokenize each string on the line and reverse it, then output it.

Input[edit]

I love you.
You love me.
We're a happy family.
The Graph Problems are more difficult then String parsing problems!

Output[edit]

I evol .uoy
uoY evol .em
er'eW a yppah .ylimaf
ehT hparG smelborP era erom tluciffid neht gnirtS gnisrap !smelborp

Solutions[edit]

References[edit]