Python Practice › String Programs › Program 101
Swap case
Write a Python program to swap upper and lower case.
Input
"Learning Python"
Output
lEARNING pYTHON
Approach
swapcase().
Solution
print("Learning Python".swapcase())Output
lEARNING pYTHON
Learn the concept
New to this topic? Read the lesson, then come back.