THE CHALLENGEALPHABET — The alphabet forwards, then backwards.
Print the capital-letter alphabet first from A to Z, then from Z to A, each on its own line. Use a loop.
Output:
ABCDEFGHIJKLMNOPQRSTUVWXYZ
ZYXWVUTSRQPONMLKJIHGFEDCBA
Challenge: typing the alphabet by hand is not allowed - build it with chr() and ONE single loop.
Checks (verified automatically before your code runs):
- At least 1 call to chr().
- At most 1 loop in the whole program (for, while and comprehensions all count).
Hint: chr(65) is "A". A slice [::-1] reverses a string.