Python Online Compiler
Example: Python program to convert the reverse case of an input character
C
C++
C#
Java
Python
PHP
main.py
STDIN
Run
# Python program to convert the reverse case of an input character print ("Enter an alphabet character to convert: ", end="") random_char = str (input ())[0] print ("The Reverse case of the '", random_char, "' is: ' ", end="") if random_char.islower(): random_char = random_char.upper() else: random_char = random_char.lower() print (random_char,"'")
D
Output
Clear
ADVERTISEMENTS