diff --git a/sent-struct.lsp b/sent-struct.lsp index 99c1813..64b5f20 100644 --- a/sent-struct.lsp +++ b/sent-struct.lsp @@ -99,7 +99,7 @@ (if (<= 5 (random 10)) (setf sentence (format nil "~A ~A" sentence (find-pos words "ADJECTIVE" 'false))) ) - (setf sentence (format nil "~A ~A; ~A ~A" sentence (find-noun-with-article words) (find-noun-with-article words) (find-pos words "PREPOSITION" 'false) (find-place-noun words))) + (setf sentence (format nil "~A ~A ~A; ~A ~A" sentence (find-noun-with-article words) (find-noun-with-article words) (find-pos words "PREPOSITION" 'false) (find-place-noun words))) sentence)) (lambda () "You must meet at and retrieve the [random(, .5)] " diff --git a/splork.lsp b/splork.lsp index e218559..bce0b2b 100644 --- a/splork.lsp +++ b/splork.lsp @@ -74,7 +74,8 @@ (apply (eval x) '())) (defun splork () - (let* ((compiled-results '()) + (let* ((sent-index nil) + (compiled-results '()) (generated-sentence "")) (setf compiled-results (mapcar #'exec-lambda *sentence-structures*)) (setf sent-index (random (length compiled-results)))