Solution:If a code is constructed in such a way that when we replace 1 by 0 and 0 by 1 in the 4-bit code representation of a digit, it is called a self-complementing code. For example, the (2421) and the (5211) codes are self- complementing.
A necessary condition for a self-complementing weighted code is that the sum of its weights be 9. Digit 8421 and 5421 codes are not self complimenting codes whereas 5211, 2421, 3321, 4311 are self complimenting.