program abc;
var a,y:real;
begin
readln(a);
if a>1000 and a<10000 or a=1000 then begin
y:=a div 1000;
end;
Writeln;
end.
var a,y:real;
begin
readln(a);
if a>1000 and a<10000 or a=1000 then begin
y:=a div 1000;
end;
Writeln;
end.