correct implementation of contains of Chord