2010-2011

Аквариум                                                                                       (10 баллов )

Решение

var a,b,c:longint;
begin
read(a,b);
if a div 3>=b then begin writeln('NO');writeln('0');end;
if a div 3<b then begin writeln('YES');writeln(b-a div 3);end;
end.