2. How many ordered pairs of integers $(a, b)$ are there such that $|a|+|b|<2019$?
First method:

Let's look at how many ordered pairs of natural numbers $(a, b)$ satisfy the conditions of the problem.

If $a=1$, then $b$ can take the values $1,2,3, \ldots, 2017$.

If $a=2$, then $b$ can take the values $1,2,3, \ldots, 2016$.

$$
\vdots
$$

If $a=2017$, then $b$ can only take the value 1.

Thus, the number of ordered pairs $(a, b)$, where $a$ and $b$ are natural numbers, is:

$$
1+2+\cdots+2017=\frac{2018 \cdot 2017}{2}=2035153
$$

Now let's look at how many ordered pairs $(a, b)$ satisfy the conditions of the problem, where $\boldsymbol{a}$ and $\boldsymbol{b}$ are integers different from zero.

From the condition $|a|+|b|<2019$, it follows that for each ordered pair of natural numbers $(a, b)$ that satisfies the condition of the problem, we can associate ordered pairs of integers of the form $(a,-b),(-a, b),(-a,-b)$
which also satisfy the conditions of the problem.

The number of ordered pairs of integers $(a, b)$, where $a$ and $b$ are integers different from zero, is $4 \cdot 2035153=8140612$.

It remains to count the ordered pairs $(a, b)$ in which at least one of the members is equal to zero. If $a=0$, then according to the condition of the problem, $|b|<2019$.

The number of integers $b$ that satisfy this condition is $2 \cdot 2018+1=4037$.

Similarly, if $b=0$.

The number of ordered pairs of integers $(a, b)$, in which at least one of the members is equal to zero, is $4037+4037-1=8073$ (the ordered pair $(0,0)$ has been counted twice).

In total, there are $8140612+8073=8148685$ ordered pairs of integers $(a, b)$ with the desired property.

Note: