PROGRAMMING:The number of 1
###Task description
Given a positive decimal integer n, write down all integers from 1 to N, and then count the number of "1" that appears in it.
For example, when n = 2, write 1,2. In this way, there is only one "1"; When n = 12, write 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12. So there are five "ones".
###Input format:
Positive integer n. 1 <= n <= 10000。
###Output format:
A positive integer, that is, the number of "1".
###Input example:
```in
twelve
```
###Output example:
```out
five
```
###Title Source
Reference code
Note: this topic is selected from openjudge website http://noi.openjudge.cn/ch0105/40/
answer:If there is no answer, please comment
Given a positive decimal integer n, write down all integers from 1 to N, and then count the number of "1" that appears in it.
For example, when n = 2, write 1,2. In this way, there is only one "1"; When n = 12, write 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12. So there are five "ones".
###Input format:
Positive integer n. 1 <= n <= 10000。
###Output format:
A positive integer, that is, the number of "1".
###Input example:
```in
twelve
```
###Output example:
```out
five
```
###Title Source
Reference code
Note: this topic is selected from openjudge website http://noi.openjudge.cn/ch0105/40/
answer:If there is no answer, please comment