#include <iostream>
#include <vector>
#include <tuple>
using namespace std;

vector<tuple<int,int,int>> sol;

int main() {
    ios_base::sync_with_stdio(false); cin.tie(0);
    int L, R; cin >> L >> R;
    int x = R-L+1;
    int n = 0; while((1LL << (n+1)) <= x-1) n++;
    for (int i = 0; i <= n; i++) {
        sol.push_back(make_tuple(0, i+1, L));
        for (int j = 0; j < i; j++) sol.push_back(make_tuple(j+1, i+1, (1<<j)));
    }
    sol.push_back(make_tuple(0, n+2, L));
    int nxt = 1;
    for (int i = 0; i <= n; i++) {
        if((x-1)&(1<<i)) {
            sol.push_back(make_tuple(i+1, n+2, nxt));
            nxt += (1<<i);
        }
    }
    cout << "YES\n";
    cout << n+3 << " " << sol.size() << "\n";
    for (int i = 0; i < sol.size(); i++)
        cout << get<0>(sol[i])+1 << " " << get<1>(sol[i])+1 << " " << get<2>(sol[i]) << "\n";
    return 0;
}
