(defun set-link (a b)
(if (eq a nil)
b
(progn
(setf prev (cdr a))
(setf (cdr a) b)
(set-link prev a))))
(defun revert (list)
(set-link list nil))
(print (revert '(a b c d e)))
CihkZWZ1biBzZXQtbGluayAoYSBiKQogICAgKGlmIChlcSBhIG5pbCkKICAgICAgICBiCiAgICAgICAgKHByb2duCiAgICAgICAgICAgIChzZXRmIHByZXYgKGNkciBhKSkKICAgICAgICAgICAgKHNldGYgKGNkciBhKSBiKQogICAgICAgICAgICAoc2V0LWxpbmsgcHJldiBhKSkpKQoKKGRlZnVuIHJldmVydCAobGlzdCkgCiAgICAoc2V0LWxpbmsgbGlzdCBuaWwpKQoKKHByaW50IChyZXZlcnQgJyhhIGIgYyBkIGUpKSk=