;;AUTOLOAD: nth-for-num
;;AUTODOC: nth-for-num "english postfix to litteral number"
;;(nth-for-num N) 
;;
;;Returns a string:
;;"st" for 1, "nd" for 2, "rd" for 3... etc, to be used in
;;(print-format "%0%fnth-for-num0 element: " 2) ==> 2nd element:

(defvar nth-for-num:table (Hashtable '(
      1 "st"
      2 "nd"
      3 "rd" 
)))      

(defun nth-for-num (arg)
  (get nth-for-num:table (mod (abs arg) 10) "th")
)

;;AUTOLOAD: nth-for-num-incr

;; same as above, but increments of one

(defun nth-for-num-incr (num) 
  (if (typep num Int) 
    (nth-for-num (+ num 1))
    ""
  )
)

;;AUTOLOAD: num-incr-one

(defun num-incr-one (num) (if (typep num Int) (+ num 1) num))
