Ad
  • Default User Avatar

    You have two cases for each alpha character:
    1.) Is the location of the letter odd or even? Go to lowercase or uppercase respectively.
    2.) After 'Z', we must loop back to 'A' (or 'z' to 'a')

    What happens if the original string has a 'Y' in a location that is odd?

    Example:
    AYE AYE CAPTAIN!!
    1.) AyE AyE CaPtAiN!! -> Alternate case
    2.) CaG CaG EcRvCkP!! -> Shift by 2

    You can see that 'Y' in this specific case goes to 'a'.

  • Default User Avatar

    Where did you view that Y? The transformation depends on where it is in a word or sentence. Read again description and examples.

  • Default User Avatar

    Please give the language and the sentence you are speaking of.