program main
  integer k, a, b
  read (*, *) k, a, b
  
  if (a - a / k * k == 0) then
    write (*, *) "OK"
    stop
  endif
  
  if (b - b / k * k == 0) then
    write (*, *) "OK"
    stop
  endif
  
  if (b / k - a / k > 0) then
    write (*, *) "OK"
    stop
  endif
  
  write (*, *) "NG"
end program main
