eolymp
Competitions

Lesson 4. September 24 - 30. Loops: while statement

Three digit numbers

Find all three digit numbers with sum of digits equals to n.

Input

One integer n (0n28).

Output

Print in the first line the number of found three digit numbers. In the next lines print these numbers in increasing order.

Time limit 1 second
Memory limit 128 MiB
Input example #1
3
Output example #1
6
102
111
120
201
210
300