A code of minimum Hamming distance d detects every pattern of at most d−1 errors and uniquely corrects every pattern of at most ⌊(d−1)/2⌋ errors. The correction claim follows because Hamming balls of that radius around distinct codewords are disjoint.