import std.stdio;

void main() {
	int animals, legs;
	readf("%s %s", &animals, &legs);

	if (legs % 2 != 0) {
		writeln("No");
		return;
	}

	auto turtles = legs / 2 - animals;

	if (turtles >= 0 && turtles <= animals) {
		writeln("Yes");
	} else {
		writeln("No");
	}
	
	writeln(turtles);
}
