+ 1

code coach no numerals with regex

Dear all I have finally finished my code for the no-numerals code coach task with python Now i would like to get your input how to improve it, make it more elegant. I decided to train in using regex, but i feel like my solution doesn't use the "re" modules full potential. any input is welcome https://code.sololearn.com/cFLwPF6nhs3N/#py best regards

13th May 2020, 9:07 PM
cedi
cedi - avatar
1 Resposta
+ 3
You can use a function or lambda expression to determine the replacement. That allows to match all numbers with one regular expression. https://code.sololearn.com/cd27BXzZoDfS/?ref=app
13th May 2020, 9:48 PM
Manu_1-9-8-5
Manu_1-9-8-5 - avatar