#include #include #include #include #include #include #include #include #include #include #include #include using namespace std; typedef long long ll; typedef pair pi; typedef pair pl; int main() { ll N, M, X, Y; cin >> N >> M; cin >> X >> Y; ll hanako, tarou; if ((X / M) % 2 == 0) { hanako = X % M; if (X%M == 0)hanako = 1; } else { int a = X % M; if (X % M == 0)a = 1; hanako = (M - a) + 1; } if ((Y / M) % 2 == 0) { tarou = Y % M; if (Y%M == 0)tarou = 1; } else { int a = Y%M; if (Y%M == 0)a = 1; tarou = (M- a) + 1; } if (hanako == tarou)cout << "YES" << endl; else cout << "NO" << endl; return 0; }