0
Getting error in No numerals problem
As per the AC my code is working Don't know why they are not accepting please help with this problem https://code.sololearn.com/cjFFtfwQ3pWJ/?ref=app
3 Antworten
+ 1
Thanks Benjamin Jürgens Bhavya Sarraf 🙌
0
You also have to replace "10" with "ten"
0
Shorter version:
sent = (input())
dict = {"1": "one", "2": "two", "3": "three", "4": "four", "5": "five", "6": "six", "7": "seven", "8": "eight", "9":"nine", "10": "ten"}
sentlst = sent.split(" ")
print(" ".join([dict.get(n, n) for n in sentlst]))