#include <stdio.h>
#include <stdlib.h>
void Quit(const char * message)
{
    printf("%s\n", message);
    exit(0);
}
int x1, y1, a1, b1, x2, y2, a2, b2;
bool under(int x, int y)
{
    return b1*1ll*x+a1*1ll*y<=a1*1ll*b1;
}
void swap(int& a, int& b)
{
    int c; c=a, a=b, b=c;
}
bool Cross(int a, int b, int c, int d)
{
    if(a>b) swap(a, b);
    if(c>d) swap(c, d);
    return !((a>d)||(c>b));
}
int main()
{
	freopen("trian.in", "r", stdin);
	freopen("trian.out", "w", stdout);
	scanf("%d%d%d%d%d%d%d", &x1, &y1, &a1, &b1, &x2, &y2, &a2, &b2);
    for(int i=0; i<2; ++i)
	{
        swap(x1, x2); swap(y1, y2); swap(a1, a2); swap(b1, b2);
        if(a1<0) x1*=-1, a1*=-1, x2*=-1, a2*=-1;
        if(b1<0) y1*=-1, b1*=-1, y2*=-1, b2*=-1;
        x2-=x1, y2-=y1, x1=0, y1=0;
        if(under(x2, y2) || under(x2+a2, y2) || under(x2, y2+b2)) Quit("YES");
	}
    if(Cross(x2, x2+a2, 0, 0) && Cross(y2, y2, 0, b1)) Quit("YES");
    if((y2==0) && Cross(x2, x2+a2, 0, a1)) Quit("YES");
    if(Cross(y2, y2+b2, 0, 0) && Cross(x2, x2, 0, a1)) Quit("YES");
    if((x2==0) && Cross(y2, y2+b2, 0, b1)) Quit("YES");
    Quit("NO");
    return 0;
}
