swapcase()将字符串中的字母小写变大写、大写变小写,举个例子:1 a = "hELLO wORLD" 2 a1 = a.swapcase() 3 print(a1)输出结果:Hello World