First, let me elaborate the upper bound from @kodlu’s answer. If $q$ is a power of a prime, then $q^2$ words suffice for $L=q+1$ (for $L=q$ it is almost trivial, improving by $1$ needs just a bit more). Then, doubling $L$ increases the number of words by $q(q-1)$, so for those values of $L$ it suffices to take $q(q-1)\log_2\frac L{q+1}+q^2$ words.

Let me show a somewhat close lower bound. Let $w$ be the number of words; set $k=w-q(q-1)+1$. Take any $k$ words. Let $v_i$ be a vector composed from all $i$th entries of the $k$ words. If two of those vectors, say $v_i$ and $v_j$, coincide, this means that at most $w-k=q(q-1)-1$ words differ in positions $i$ and $j$, so not all pairs are covered.

Thus, we have $L$ distinct vectors in $[q]^k$, so $L\leq q^k$, or $w\geq q(q-1)+1+\log_qL$.

Therefore, the growth rate is indeed logarithmic (but the constant at the logarithm is yet unclear).

**Addendum.** Let me present an example for $L=q+1$, when $q$ is a power of a prime.

Consider an affine plane $\mathbb F_q^2$. All lines in it are partitioned into $q+1$ classes $C_1,\dots,C_{q+1}$ of mutually parallel lines (one class consists of all lines with equations of the form $ax+by=c$ with fixed $(a:b)$). Enumerate the lines in each class by numbers from 1 to $q$.

For each point $p\in \mathbb F_q^2$, take a word $w_1\dots w_{q+1}$ where $w_i$ is the number of the line in $C_i$ passing through $p$. Then, for any two classes $C_i$ and $C_j$ and for any two lines in them, the lines meet at a unique point, which means exactly what we need to get in the $i$th and $j$th positions.

orthogonal arrayof strength $t=2$ and repetition $\lambda=1$ over a $q-$ary alphabet. This is an array of symbols from the alphabet, where looking down any two columns each possible pair of symbols appear once. There is a large literature on this subject. $\endgroup$1more comment