#include <iostream>
#include <vector>
#include <cmath>
#include <string>
#include <climits>
#include <iomanip>
#include <algorithm>
#include <queue>
#include <map>
#include <tuple>
#include <iostream>
#include <deque>
#include <array>
#include <set>
#include <functional>
#include <memory>
#include <stack>
#include <numeric>
#include <climits>
#include <cfloat>
struct Vector;
struct Point {
	int x, y;
	Vector operator-(const Point& that) const;
	bool operator==(const Point& that) const;
};
struct Vector {
	Point from, to;
	int dx() const;
	int dy() const;
	int cross(const Vector& that) const;
	int dot(const Vector& that) const;
	bool is_left(const Point& that) const;
	bool is_right(const Point& that) const;
	bool is_on_line(const Point& that) const;
	bool is_forward(const Point& that) const;
	bool is_backward(const Point& that) const;
};

bool is_separated_by_white_to_white_line(const Vector& vec, const std::vector<Point>& black, const std::vector<Point>& white) {
	return
		(std::all_of(black.begin(), black.end(), [vec](const Point& p) {return vec.is_left(p); }) && std::all_of(white.begin(), white.end(), [vec](const Point& p) {return vec.is_right(p) || vec.is_on_line(p); })) ||
		(std::all_of(black.begin(), black.end(), [vec](const Point& p) {return vec.is_right(p); }) && std::all_of(white.begin(), white.end(), [vec](const Point& p) {return vec.is_left(p) || vec.is_on_line(p); }));
}
bool is_separated_by_black_to_white_line(const Vector& vec, const std::vector<Point>& black, const std::vector<Point>& white) {
	return
		(std::all_of(black.begin(), black.end(), [vec](const Point& p) {return vec.is_left(p) || vec.is_forward(p); }) && std::all_of(white.begin(), white.end(), [vec](const Point& p) {return vec.is_right(p) || vec.is_backward(p); })) ||
		(std::all_of(black.begin(), black.end(), [vec](const Point& p) {return vec.is_left(p) || vec.is_backward(p); }) && std::all_of(white.begin(), white.end(), [vec](const Point& p) {return vec.is_right(p) || vec.is_forward(p); })) ||
		(std::all_of(black.begin(), black.end(), [vec](const Point& p) {return vec.is_right(p) || vec.is_forward(p); }) && std::all_of(white.begin(), white.end(), [vec](const Point& p) {return vec.is_left(p) || vec.is_backward(p); })) ||
		(std::all_of(black.begin(), black.end(), [vec](const Point& p) {return vec.is_right(p) || vec.is_backward(p); }) && std::all_of(white.begin(), white.end(), [vec](const Point& p) {return vec.is_left(p) || vec.is_forward(p); }));
}
int main() {
	while (true) {
		int n, m; std::cin >> n >> m; if (n == 0 && m == 0) break;
		std::vector<Point> white(n), black(m); for (auto& w : white) std::cin >> w.x >> w.y; for (auto& b : black) std::cin >> b.x >> b.y;
		auto can_separate = false;
		for (auto i = 0; i < n && !can_separate; ++i) {
			const auto base = white[i];
			for (auto j = i + 1; j < n && !can_separate; ++j) {
				const auto vec = base - white[j];
				can_separate |= is_separated_by_white_to_white_line(vec, black, white);
			}
			for (auto j = 0; j < m && !can_separate; ++j) {
				const auto vec = base - black[j];
				can_separate |= is_separated_by_black_to_white_line(vec, black, white);
			}
		}
		if (can_separate) std::cout << "YES\n";
		else std::cout << "NO\n";
	}
}

int Vector::dx() const
{
	return to.x - from.x;
}

int Vector::dy() const
{
	return to.y - from.y;
}

int Vector::cross(const Vector& that) const { return dx() * that.dy() - dy() * that.dx(); }

int Vector::dot(const Vector& that) const
{
	return dx() * that.dx() + dy() * that.dy();
}

bool Vector::is_left(const Point& that) const
{
	return cross(that - from) < 0;
}

bool Vector::is_right(const Point& that) const
{
	return cross(that - from) > 0;
}

bool Vector::is_on_line(const Point& that) const
{
	return cross(that - from) == 0;
}

bool Vector::is_forward(const Point& that) const
{
	return is_on_line(that) && dot(that - from) >= 0;
}

bool Vector::is_backward(const Point& that) const
{
	return is_on_line(that) && dot(that - from) <= 0;
}

Vector Point::operator-(const Point& that) const { return Vector{ *this, that }; }

bool Point::operator==(const Point& that) const { return x == that.x && y == that.y; }


Measured memory_bytes: 3012