Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
45370 | 蔡璟恒 | 字符串的奇偶性 | Python3 | Accepted | 32 MS | 3752 KB | 435 | 2023-03-19 15:25:09 |
l=[] while True: x=input() if x=="#": break l.append(x) for i in l: count=0 for j in i[:len(i)-1]: if j=="1": count+=1 print(i[:len(i)-1],end="") if i[len(i)-1:]=="e": if count%2==0: print("0") else: print("1") else: if count%2==0: print("1") else: print("0")