(defun flatten (tr) (cond ((null tr) nil) ((atom tr) (list tr)) (t (append (flatten (first tr)) (flatten (rest tr))))))