+ 2
No numerals problem
Why i cant pass test case 3 my code seems correct?? h=input().split() dic={0:"zero",1:"one",2:"two",3:"three",4:"four",5:"five",6:"six",7:"seven",8:"eight",9:"nine"} no_nemerals=[dic[int(word)] if word.isdigit() and int(word)<10 else word for word in h] print(" ".join(no_nemerals))
1 Respuesta
+ 6
Your code doesn't handle the case when one inputs "10", e.g. "1 queen and 10 honey bees".
Note that in the instructions it says that a number can also be 10.
Tag the relevant programming language instead of "?"