Skip to content

Instantly share code, notes, and snippets.

@fronx
Created August 2, 2011 10:10
Show Gist options
  • Select an option

  • Save fronx/1119954 to your computer and use it in GitHub Desktop.

Select an option

Save fronx/1119954 to your computer and use it in GitHub Desktop.
(pop [1 2 3])
; => [1 2]
(pop '(1 2 3))
; => (2 3)
;;
(seq (pop (vec '(1 2 3))))
; => (1 2)
(reverse (pop (reverse '(1 2 3))))
; => (1 2)
;;
(butlast '(1 2 3))
; => (1 2)
(butlast [1 2 3])
; => (1 2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment