program atcoder
implicit none
integer :: l , r , d , n
read *,l , r , d
if(l == 1)then
  print *, r/d
else if (mod(l,d) == 0)then
  n = int(r/d) - int(l/d) + 1
  print *,n
else
  n = int(r/d) - int(l/d)
  print *,n
end if
end program atcoder