Digit to Word

Sometimes a number needs to be shown to the user as a clear word instead of a digit. Write a function switch_it_up that takes a number number from 0 to 9 and returns its English name. For example, 0 becomes Zero, and 3 becomes Three.

Примеры

Ввод
1
Вывод
"One"
Ввод
3
Вывод
"Three"
Ввод
0
Вывод
"Zero"

Нужно реализовать

def switch_it_up(number: int) -> str:

Теги

stringsmath
PostgreSQLv16

Koodin suorituksen tulos näkyy tässä

Visible tests
1
Input
1
Expected"One"
2
Input
3
Expected"Three"
3
Input
0
Expected"Zero"
4
Input
9
Expected"Nine"
5
Input
5
Expected"Five"
6
Input
-1
Expected"Nine"
Focus radio
Paused · SomaFM · Fluid