Created
December 12, 2016 00:16
-
-
Save lispm/2c745a42c697fe945c15da0000ec6afe to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (defun abbreviate-butlast (path) | |
| (loop for (item . rest) on path | |
| collect (if (and rest (> (length item) 1)) | |
| (subseq item 0 1) | |
| item))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment