Ad
  • Default User Avatar

    Could the possible inputs be described more in details, especially regarding punctuation?
    Is punction always single? Is punctuation always preceeded by a space?

    Is "Once upon a time, in a country far far away..." considered as a valid input?
    Or would inputs always be like "Once upon a time , in a country far far away . . ." ? (each punctation mark being preceeded by a space)

    Suggestion:

    1> Move the first letter of each word to the end of it, then add "ay" to the end of the word. Leave punctuation marks untouched. Punctuation will always be a single mark, preceeded by a white space.

    2> Move the first letter of each word to the end of it, then add "ay" to the end of the word. Leave punctuation marks untouched. Punctuation might be composed of single or multiple characters (e.g. "!" or "...") and may or may not be preceeded by a space (e.g. "word !" or "word,").

  • Default User Avatar

    @MMMAAANNN's comment was VERY helpful!

    but why is part #1 available in 100 languages, and part 2 / 3 / 4 available in Python only? :-(

    I cannot check my solution in C# for this part #2.

  • Default User Avatar

    geezz.... thx for you comment! helped me solve the same issue. even 6 years after it was publish, your comment still has good value (at least to me!)