#include int main() { int a,b; scanf("%d %d",&a,&b); int p=(a+1)-b; printf("%s\n%d\n",(p<=0?"YES":"NO"), (p<0?p*-1:p)); }