字符串个数统计。 while True: try: str_input = input() num = [] for i in str_input: if i in num: continue else: num.append(i) print(len(num)) except: break