def point_before(self, x):
    '(x,y) of the point left of x, or None'
    leftidx = self.index_before(x)
    if (leftidx is None):
        return None
    return self.points[leftidx]
(x,y) of the point left of x, or None
def point_before(self, x):
    
    leftidx = self.index_before(x)
    if (leftidx is None):
        return None
    return self.points[leftidx]