Advertisement
Guest User

Untitled

a guest
Nov 6th, 2018
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lisp 0.14 KB | None | 0 0
  1. (defun fib-loop (n)
  2.   (cons 1
  3.     (loop with a = 0 and b = 1
  4.           repeat n
  5.           do (psetf a b b (+ a b))
  6.           collect b)))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement