Write a programExercise 3/4Elementary20 XP

Alternating letters

Task

The program reads a text and prints it so that the characters at even indexes (0, 2, 4, …) are lower case and those at odd indexes upper case. python becomes pYtHoN. Characters that are not letters (spaces, digits) stay the same.

Examples

  • Input

    python

    Expected output

    pYtHoN

After you submit, 5 hidden tests will also check your solution: capitals in the input, one character, with a space, with digits, with accents.

Python starts the first time you run code.

Ctrl+Enter runs the program. Tab indents. Press Esc, then Tab, to leave the editor.

Input (stdin)

Each line = one call to input().

Output

Hints

Try it yourself first. Each hint reveals a little more - and lowers the reward a little.

Signed out, hints are free - but no XP is awarded either.

Solution

The solution unlocks after the last hint.