The performance of low-density parity-check codes is investigated via methods of statistical mechanics. Low-density parity-check codes is first invented by Gallager, which was abandoned shortly after its introduction due to the limited computational abilities and recently rediscovered by MacKay and Neal as MN codes. In these codes, a message is encoded to the codeword which comprises products of the message bits selected by two randomly-constructed sparse matrices. The typical case analysis of statistical mechanics indicates a practical property of the particular family of the codes, which could not be found within the framework of worst case analysis. Further, decoding aspects are considered by investigating solutions obtained by a mean field approach, which is identical to the commonly used belief propagation.