Error in test #468?

  • 0

    In test # 468 i get as detailed output:

    Input: "Yo! Bottoms up
    U.S. Motto

    Output: "yo! Bottoms Up, u.S. Motto, boY!"

    Expected: "Yo! Bottoms Up, u.S. Motto, boy!"

    I cant understand why expected output string start from big "Y"? Programm must swap first and last vowels. For this example it will be Y and y, so the result string will be starts from small y. Does we need to save letters case?

  • 1

    y is not vowel, so keep same. In the loop for looking for vowel, it will skip 'Y'.
    So u may check ur pointer.

  • 0

    Thanks, didnt note it)

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.