-->
当前位置:首页 > 题库

PROGRAMMING:Output all palindromic numbers of < = n (higher education society, exercise 4-5 of Python programming basis and application)

Luz5年前 (2021-05-10)题库379
Reading 121 from left to right is the same as reading 121 from right to left. This number is called palindrome number. Please use the for loop and slicing method to design a program,
Find all palindromic numbers > = 0 and < = n.
Note: single numbers 0, 1,... And 9 are also considered palindromic numbers.
###Input format:
n
###Output format:
Multi line output, one number per line
###Input example:
```in
thirteen
```
###Output example:
```out
0
one
two
three
four
five
six
seven
eight
nine
eleven
```







answer:If there is no answer, please comment