program pr1
  implicit none
  integer :: a,b,c, i, j, k
  read(*,*) a, b, c
  j = 0
  do i = a, b
     if ( mod(i,c) == 0 ) then
        j = j + 1
     end if
  end do
  write(*,'(i0)') j

  stop
end program pr1
