6. Given $a_{1}, a_{2}, \cdots, a_{2019} \in[0,2]$. Find the range of $\sum_{1 \leqslant j \leqslant k \leqslant 2019}\left|a_{j}-a_{k}\right|$.
Let $0 \leqslant a_{1} \leqslant a_{2} \leqslant \cdots \leqslant a_{2019} \leqslant 2$.
Fix $a_{2}, a_{3}, \cdots, a_{2019}$, the original expression achieves its maximum value if and only if $a_{1}=0$;

Fix $a_{1}, a_{2}, \cdots, a_{2018}$, the original expression achieves its maximum value if and only if $a_{2019}=2$;
and so on.
Therefore, $\sum_{1 \leqslant j<k \leqslant 2019}\left|a_{j}-a_{k}\right|$ achieves its maximum value when $a_{1}=a_{2}=\cdots=a_{1009}=0, a_{1011}=a_{1012}=\cdots=a_{2019}=2$, which is $2 \times 1010 \times 1009$. It is easy to see that the minimum value is 0.