救命!Python一直RE,大神们,我是学生党能帮帮我吗 (家境贫寒)
char = list(input());sum = 0;number =[1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,4,1,2,3,1,2,3,4] for temp in range (0,len(char)): if char[temp] == ' ': sum += 1 else: sum += number[ord(char[temp])-ord("a")] print (sum)