{-------------------------------

 -------------------------------
  # Max Tkachenko # Group 112 #
 -------------------------------
}

Program task_3_29___D(input,output);

var 
    a : real;
    res : boolean;

 begin
  readln(a);
  
     res := (trunc(a*10)mod 10=0) or
                 (trunc(a*100) mod 10=0) or
                  (trunc(a*1000)mod 10=0);

  writeln (res);
 end.
