# https://yukicoder.me/problems/no/396 def select_class(class_M, rank): ans = rank % (2 * class_M) if ans == 0: return 1 elif ans > class_M: return ans - (2 * (ans - class_M) - 1) else: return ans def main(): _, M = map(int, input().split()) X, Y = map(int, input().split()) print(['NO', 'YES'][select_class(M, X) == select_class(M, Y)]) main()