(defun solver ()
  (let ((k (read)) (count 0) current  (temp 1))
    (loop for i from 2 do
          (when (= count k) (return))
          (setf current (/ i (apply #'+ (int-to-digit i))))
          (when (<= temp current)
            (format t "~a~%" (1- i)) (incf count))
          (setf temp current))))

(solver)