Mountain words X52420


Statement
 

pdf   zip

html

Input

Each line will contain one upper case word up to 12 characters long. The last line of the input contains a single #.

Output

Print the corresponding mountains, one after the other, for given words.

Public test cases
  • Input

    HAT
    GREAT
    FOUR
    #
    

    Output

              T
             AAT       R
      T     EEEAT     UUR
     AAT   RRRREAT   OOOUR
    HHHAT GGGGGREAT FFFFOUR
    
  • Input

    A
    #
    

    Output

    A
    
  • Information
    Author
    HP CodeWars
    Language
    English
    Official solutions
    Python
    User solutions
    Python