Simple Sand Samples |
Gauche > 文字列を一文字毎に分割する
split-char.scm
(define src "HELLO") (define dst (string->list src)) (map (lambda (x) (print "[" x "]" )) dst)
$ gosh split_scm.scm
[H]
[E]
[L]
[L]
[O]
$
[H]
[E]
[L]
[L]
[O]
$
* 確認環境 Debian Linux(Wheezy)