CT941

The Shimmering ribbons of Hema

EasyL2 · Byte BanditAcceptance: 0.0%XP: 10

Hema found an old ledger of ribbons in the bakery attic at the foggy moor of Greyfen. The margin notes pose a precise question. Task: Read a line of space-separated words and print the words in reverse order. Input format: One line with words separated by single spaces. Output format: Print the words in reverse order, single-spaced. Constraints: 1 <= |s| <= 127; s contains lowercase English letters.

Example 1:

Input: ewalyz umspzvtgg b cmglqjdxfsb zevzqx rihknfdflq wwhhklpd y zswvctqohroh ieifizlpm yqnniuodoaf ahnnz cewsvpmxfdvs
Output: cewsvpmxfdvs ahnnz yqnniuodoaf ieifizlpm zswvctqohroh y wwhhklpd rihknfdflq zevzqx cmglqjdxfsb b umspzvtgg ewalyz

Example 2:

Input: hgkzlbncfk cww dawnhnpbqmm cvgpajit yjqkokgshg nhbwy tfq xthbxv bxkitnqc rxfygmnaxn jlpvyqjt nhoylxyyv
Output: nhoylxyyv jlpvyqjt rxfygmnaxn bxkitnqc xthbxv tfq nhbwy yjqkokgshg cvgpajit dawnhnpbqmm cww hgkzlbncfk

Example 3:

Input: g j mqfby citincakp ufyaxyjge wgjvaojjhafg hex xpwu eedaiowc crrcqt ou v
Output: v ou crrcqt eedaiowc xpwu hex wgjvaojjhafg ufyaxyjge citincakp mqfby j g

Constraints:

1 <= |s| <= 127; s contains lowercase English letters.

Loading...
Test Cases:No test cases
No test cases available.