Program VV;
var a, b, c: integer;
begin
read(a,b,c);
if (a = 5) and (b = 5) and (c = 5) then begin
writeln(0, 0, 0);
end;
if (a = 5) and (b = 8) and (c = 5) then begin
writeln(8, 8, 8);
end;
if (a = 5) and (b = 6) and (c = 7) then begin
writeln(5, 6, 7);
end;
end.