Discussion
Hamming distance of the following code words A and B is ................ .
A = 001001001001 and
B = 110100100110
Answer: C
The Hamming distance is 10.
The Hamming distance between two code words of equal length is the number of positions in which they differ, that is, the number of 1s in their bitwise XOR.
| A | 0010 0100 1001 |
| B | 1101 0010 0110 |
| A XOR B | 1111 0110 1111 |
The XOR has 4 + 2 + 4 = 10 ones, so the words differ in 10 of their 12 positions. They agree only in positions 5 and 8. Counting only part of the word, or counting the agreeing positions, produces the smaller distractors.
No comment is present. Be the first to comment.
Loading…
Post your comment
Please log in or register to post a comment.
Examination Categories
- SSC Exams
- Banking Exams
- Teaching Exams
- Civil Services Exams
- Railways Exams
- Engineering Recruitment Exams
- Defence Exams
- State Government Exams
- Police Exams
- Insurance Exams
- Nursing Exams
- Other Government Exams
- NRA CET
- PG Entrance Exams
- Campus Placement
- MBA Entrance Exams
- CUET and UG Entrance
- Judiciary Exams
- Regulatory Body Exams
- Software Development