#C5522. Digit Sum Sequence

    ID: 49181 Type: Default 1000ms 256MiB

Digit Sum Sequence

Digit Sum Sequence

Given a positive integer \( n \) (with \(1 \leq n \leq 10^4\)), compute a sequence where the \( i \)-th element is the sum of the digits of the integer \( i \) for all \( i \) from 1 to \( n \).

For example, when \( n = 13 \), the sequence is:

1 2 3 4 5 6 7 8 9 1 2 3 4

Note that for numbers with more than one digit, you must sum each digit individually. For instance, for \( i = 10 \), the sum is \(1 + 0 = 1\), and for \( i = 15 \), the sum is \(1 + 5 = 6\).

inputFormat

The input consists of a single line containing one integer \( n \) that specifies the range of numbers you need to process.

outputFormat

Output a single line with \( n \) integers separated by a single space. The \( i \)-th integer should be the sum of the digits of \( i \). For example, if \( n = 5 \), the output should be: 1 2 3 4 5.

## sample
5
1 2 3 4 5