Berlanders like to eat cones after a hard day. Misha Square and Sasha Circle are local authorities of Berland. Each of them controls its points of cone trade. Misha has *n* points, Sasha — *m*. Since their subordinates constantly had conflicts with each other, they decided to build a fence in the form of a circle, so that the points of trade of one businessman are strictly inside a circle, and points of the other one are strictly outside. It doesn't matter which of the two gentlemen will have his trade points inside the circle.

Determine whether they can build a fence or not.
The first line contains two integers *n* and *m* (1 ≤ *n*, *m* ≤ 10000), numbers of Misha's and Sasha's trade points respectively.

The next *n* lines contains pairs of space-separated integers *M*<sub class="lower-index">*x*</sub>, *M*<sub class="lower-index">*y*</sub> ( - 10<sup class="upper-index">4</sup> ≤ *M*<sub class="lower-index">*x*</sub>, *M*<sub class="lower-index">*y*</sub> ≤ 10<sup class="upper-index">4</sup>), coordinates of Misha's trade points.

The next *m* lines contains pairs of space-separated integers *S*<sub class="lower-index">*x*</sub>, *S*<sub class="lower-index">*y*</sub> ( - 10<sup class="upper-index">4</sup> ≤ *S*<sub class="lower-index">*x*</sub>, *S*<sub class="lower-index">*y*</sub> ≤ 10<sup class="upper-index">4</sup>), coordinates of Sasha's trade points.

It is guaranteed that all *n* + *m* points are distinct.
def distance(x,y,a):
    e = abs(x[0] - y[0])
    h = abs(x[1] - y[1])
    distance_ = (((e * e) + (h * h)) ** 0.5)
    return distance_


def max_distance_(a):
    set_ = [0,0,0,0]
    max_ = -1
    for i in range(len(a)):
        for j in range(i+1,len(a)):
            if (distance(a[i],a[j],a) > max_):
                max_ = distance(a[i],a[j],a)
                set_ = [a[i][0],a[i][1],a[j][0],a[j][1]]
    return max_, set_
    




n,m = map(int,input().split())
a = []
b = []
s = 0
c1 = 0
for i in range(n):
    x,y = map(int,input().split())
    a.append([x,y])
for i in range(m):
    x,y = map(int,input().split())
    b.append([x,y])
s = max_distance_(a)
max_distance = (s[0]) / 2
max_a_ = [((s[1][0] + s[1][2]) / 2),((s[1][1] + s[1][3]) / 2)]
for i in range(len(b)):
    if (distance(max_a_,b[i],b) <= max_distance):
        c1 = -1
        break
if (c1 == 0):
    print('YES')
else:
    s = max_distance_(b)
    max_distance = (s[0]) / 2
    max_b_ = [((s[1][0] + s[1][2]) / 2),(s[1][1] + s[1][3]) / 2]
    for i in range(len(a)):
        if (distance(max_b_,a[i],a) <= max_distance):
            c1 = -1
    if (c1 == 0):
        print('YES')
    else:
        print('NO')