what is swapcase in python code example
Example 1: swapcase
str_swapcase = "what was that about?".swapcase()
print(str_swapcase)
Example 2: swapping upper case and lower case string python
# swapcase() method
string = "thE big BROWN FoX JuMPeD oVEr thE LAZY Dog"
print(string.swapcase())
>>> THe BIG brown fOx jUmpEd OveR THe lazy dOG