Guest User

Untitled

a guest
May 14th, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lisp 0.42 KB | None | 0 0
  1. (defun merge-variables (input &optional output)
  2.   (if (null input)
  3.     (return-from merge-variables output))
  4.   (merge-variables
  5.     (mapcan #'(lambda (x)
  6.       (if (not (eq (caar input) (car x)))
  7.           (list x) )            
  8.     ) input)
  9.   (check-for-zero-exponential (list (car (car input))
  10.     (apply '+ (mapcan #'(lambda (x)
  11.       (if (eq (caar input) (car x))
  12.          (cdr x))            
  13.      ) input))) output)
  14.    )  
  15. )
Add Comment
Please, Sign In to add comment