#include <iostream>
using namespace std;

int main() {
	int n,p;
	cin>>n>>p;
	/*
	if (n-p<=2*(p-1)+1 && p-1<=2*(n-p-1)+1) cout<<"YES"<<endl;
	else cout<<"NO"<<endl;
	*/
	cout << (p > (n / 3) && p <= (n - (n / 3) - (n % 3 == 2 ? 1 : 0)) ? "YES" : "NO") << endl;
	return 0;
}
/*
 * 10 -> 4
 *
 * n pizzas, we want the pth
 * so p-1 below, and n-p above
 * if n-p is at most 2*(p-1+1)+1, =]
 *
 * n-p=8 , p-1=3
 * and p-1 is at most 2*(n-p), =)
 * p-1=8
 * n-p=4
 */