909 |
'sentence 'used 'was |
'sentence 'used 'was |
910 |
"..." |
"..." |
911 |
'(// bak)))) |
'(// bak)))) |
912 |
|
((memq (car sent) '(do has have how when where who why)) |
913 |
|
(doctor-type ($ qlist))) |
914 |
;; ((eq (car sent) 'forget) |
;; ((eq (car sent) 'forget) |
915 |
;; (set (doctor-cadr sent) nil) |
;; (set (doctor-cadr sent) nil) |
916 |
;; (doctor-type '(($ isee)($ please) |
;; (doctor-type '(($ isee)($ please) |
917 |
;; ($ continue)\.))) |
;; ($ continue)\.))) |
918 |
(t |
(t |
919 |
(if (doctor-defq sent) (doctor-define sent found)) |
(if (doctor-defq sent) (doctor-define sent found)) |
920 |
(if (> (length sent) 12)(doctor-shorten sent)) |
(if (> (length sent) 12)(setq sent (doctor-shorten sent))) |
921 |
(setq sent (doctor-correct-spelling (doctor-replace sent replist))) |
(setq sent (doctor-correct-spelling (doctor-replace sent replist))) |
922 |
(cond ((and (not (memq 'me sent))(not (memq 'i sent)) |
(cond ((and (not (memq 'me sent))(not (memq 'i sent)) |
923 |
(memq 'am sent)) |
(memq 'am sent)) |
958 |
(defun doctor-shorten (sent) |
(defun doctor-shorten (sent) |
959 |
"Make a sentence manageably short using a few hacks." |
"Make a sentence manageably short using a few hacks." |
960 |
(let (foo |
(let (foo |
961 |
retval |
(retval sent) |
962 |
(temp '(because but however besides anyway until |
(temp '(because but however besides anyway until |
963 |
while that except why how))) |
while that except why how))) |
964 |
(while temp |
(while temp |
965 |
(setq foo (memq (car temp) sent)) |
(setq foo (memq (car temp) sent)) |
966 |
(if (and foo |
(if (and foo |
967 |
(> (length foo) 3)) |
(> (length foo) 3)) |
968 |
(setq sent foo |
(setq retval (doctor-fixup foo) |
969 |
sent (doctor-fixup sent) |
temp nil) |
|
temp nil |
|
|
retval t) |
|
970 |
(setq temp (cdr temp)))) |
(setq temp (cdr temp)))) |
971 |
retval)) |
retval)) |
972 |
|
|
1540 |
(doctor-hates1)) |
(doctor-hates1)) |
1541 |
|
|
1542 |
(defun doctor-hates1 () |
(defun doctor-hates1 () |
1543 |
(doctor-type '(($ whysay)(list subj verb obj)))) |
(doctor-type '(($ whysay)(list subj verb obj) \?))) |
1544 |
|
|
1545 |
(defun doctor-loves () |
(defun doctor-loves () |
1546 |
(doctor-svo sent found 1 t) |
(doctor-svo sent found 1 t) |
1634 |
|
|
1635 |
(defun doctor-chat () (doctor-type ($ chatlst))) |
(defun doctor-chat () (doctor-type ($ chatlst))) |
1636 |
|
|
|
(defun doctor-strangelove () |
|
|
(interactive) |
|
|
(insert "Mein fuehrer!!\n") |
|
|
(doctor-read-print)) |
|
|
|
|
1637 |
(provide 'doctor) |
(provide 'doctor) |
1638 |
|
|
1639 |
;;; doctor.el ends here |
;;; doctor.el ends here |