In this subsection, we briefly discuss linear codes. The reader may refer to [1]}, [2]} for more details.
Let \(q\)  be a prime power and \(\mathbb {F}_q\)  be the finite field with \(q\)  elements. Let \(\mathbb {F}_q^n\)  be the vector space of dimension \(n\)  over \(\mathbb {F}_q\) .
A linear code \(\mathcal {C}\)  of length \(n\)  over \(\mathbb {F}_q\)  is an \(\mathbb {F}_q\) -subspace of \(\mathbb {F}_q^n\) .
The dimension of \(\mathcal {C}\)  is defined to be the dimension of \(\mathcal {C}\)  as a vector space over \(\mathbb {F}_q\) . Any element in \(\mathcal {C}\)  is called a codeword.
The support of a codeword \({\bf u}=(u_1,\cdots , u_n)\in C\)  is defined by \(\text{supp}({\bf u})=\lbrace i\in [n]: u_i\ne 0\rbrace ,\)  where \([n]=\lbrace 1,2,\cdots , n\rbrace .\) 
The Hamming weight \(\text{wt}(\bf u)\)  of \({\bf u}\)  is defined to be the size of \(\text{supp}({\bf u}).\) 
If \(\mathcal {C}\ne \lbrace 0\rbrace \) , then the minimum distance of \(\mathcal {C}\)  is defined to be the smallest Hamming weight of nonzero codewords in \(\mathcal {C}\) .
