Problem 4. (4 points) In how many different ways can the number 2004 be represented as the sum of natural numbers (one or several) that are approximately equal? Two numbers are called approximately equal if their difference is no more than 1. Sums that differ only in the order of the addends are considered the same.
Solution: The answer is 2004.

First method. Note that in any representation of 2004 as a sum of approximately equal addends, the sum contains at most two different addends.

We will prove that for every integer $k$ from 1 to 2004, there exists a unique representation of 2004 as a sum of $k$ approximately equal addends.

To represent 2004 as a sum of $k$ numbers, where $x$ numbers are equal to $m$ and $y$ are equal to $m+1$ (where $x+y=k$ and let $x>0$), the equation

$$
2004 = mx + (m+1)y = mk + y
$$

must be satisfied, where $0 \leq y < k$. From this, $y$ is uniquely determined - it is the remainder when 2004 is divided by $k$, and then $x = k - y$.

Therefore, the representations are a total of 2004.

Second method. We will prove by induction that the number $N$ can be represented as a sum of approximately equal addends in $N$ ways.

Note that in any such representation, at most two different addends are involved.

For the number 1, there is one representation: with one addend 1.

Assume the statement is proven for some number $N$. By adding one unit to one of the smaller addends in each representation of $N$ (or to any one if all are equal), we obtain a representation of the number $N+1$ (with the same number of addends). In this way, different representations of $N$ yield different representations of $N+1$.

Conversely, if in each representation of $N+1$ (except the representation as a sum of $N+1$ units) one of the larger addends is reduced by 1 (or, if the addends are equal, any one is reduced by 1), a representation of $N$ is obtained (with the same number of addends). In this way, different representations of $N+1$ yield different representations of $N$.

Therefore, the number of representations of the number $N+1$ is one greater than the number of representations of $N$. By induction, the statement is proven.