李艳荷

liyanhe
483 号测试 成员, 2018-11-27 13:08:10 加入
2.2k
个人主页浏览
  • Python13 期字符串大考核!!!

    2020-07-24 10:55

    w='sdSdsfdAdsdsdfsfdsdASDSDFDSFa'
    w1=w.swapcase()
    print('大小写转换后的字符串:',w1)
    new_w=''
    for i in w:
    if i.islower():
    i = chr(219-ord(i))
    new_w +=i
    elif i.isupper():
    i = chr(155 - ord(i))
    new_w +=i
    print('镜像字符串是:',new_w)

  • Python13 期字符串大考核!!!

    2020-07-24 10:55

    w='sdSdsfdAdsdsdfsfdsdASDSDFDSFa'
    print(w.swapcase())
    print(w.replace('A','Z',2))