  In this paper, we investigate the encoding circuit size of Hamming codes and
Hadamard codes. To begin with, we prove the exact lower bound of circuit size
required in the encoding of (punctured)~Hadamard codes and (extended)~Hamming
codes. Then the encoding algorithms for (punctured)~Hadamard codes are
presented to achieve the derived lower bounds. For (extended)~Hamming codes, we
also propose encoding algorithms that achieve the lower bounds.
