测评会员优惠活动进行中 · 开通 VIP,有效期内测评不限次 VIP 优惠中 · 测评不限次 立即查看

A58245. 有如下 Python 程序,运行该程序后,输出结果为?def fun(s)

单选题

题目描述

有如下 Python 程序,运行该程序后,输出结果为?

def fun(s):
    st=s[1]
    for i in range(1,len(s)):
        if len(st)==0 or s[i]!=st[len(st)-1]:
            st=st+s[i]
        else:
            st=st[0:len(st)-1]
    print(st)
fun("xxyyzzxyz")

选项(单选)