# How to generate vectors with programming

I want to generate all possible vectors programicaly with entrys in $$\Bbb Z_4$$: $$A_j:=\begin{bmatrix}x_1\\ x_2\end{bmatrix}, \qquad x_i\in \{0,1,2,3\}, j=1,2,\cdots 16.$$

Use Tuples.
Tuples[{0,1,2,3}, {2}]

• Thanks @Szabolcs. My purpose of this question was the detailed code of Tuples. – C.F.G Aug 19 at 15:11
elem = {0, 1, 2, 3}; Flatten[Outer[List, elem, elem], 1]