The communication complexity of the Hamming distance problem