add fun in kit.el

This commit is contained in:
Guobao Jiang 2014-01-22 16:41:12 +08:00
parent 077cb69ba6
commit 97084e85af
1 changed files with 12 additions and 0 deletions

View File

@ -16,3 +16,15 @@
(message "hello word")
(message "input argument are %s" argv)
(message "first argument is %s" (elt argv 0))
(message "system-type:%s system-name:%s" system-type system-name)
;(message (string-to-int))
(defun cal-salary (iday)
"Calculate the salary for intern in shanghai"
(interactive "p")
(setq value (+ 800 (* 0.8 (- (* iday 180)800))))
(setq tvalue (- (* iday 180) value))
(message "You work %d day, and salary is %d, tax is %d." iday value tvalue)
)
(cal-salary (string-to-number (elt argv 0)))