As far as I know, there is no ready-to-use splitting function in the cl standard.
However you can use the cl-split-sequence library, available through quicklisp
Assuming quicklisp is installed,
- Code: Select all
CL-USER> (ql:quickload :split-sequence)
To load "split-sequence":
Load 1 ASDF system:
; Loading "split-sequence"
CL-USER> (use-package :split-sequence)
CL-USER> (split-sequence #\space "This is an example.")
("This" "is" "an" "example.")
The code for split-sequence can be read online at the following url:http://common-lisp.net/project/clbuild/ ... uence.lisp