def _minmax(coor, minc, maxc):
    if (coor[0] < minc[0]):
        minc[0] = coor[0]
    if (coor[0] > maxc[0]):
        maxc[0] = coor[0]
    if (coor[1] < minc[1]):
        minc[1] = coor[1]
    if (coor[1] > maxc[1]):
        maxc[1] = coor[1]
    return (minc, maxc)
def _minmax(coor, minc, maxc):
    if (coor[0] < minc[0]):
        minc[0] = coor[0]
    if (coor[0] > maxc[0]):
        maxc[0] = coor[0]
    if (coor[1] < minc[1]):
        minc[1] = coor[1]
    if (coor[1] > maxc[1]):
        maxc[1] = coor[1]
    return (minc, maxc)