#include using namespace std; int main() { cin.tie(nullptr); ios::sync_with_stdio(false); int a, b; cin >> a >> b; string yes = "NO"; int out = (a + 1) - b; if(out <= 0) { yes = "YES"; out = 0; } cout << yes << '\n' << out << '\n'; return 0; }