Thanks for the answsers! Jay's last answer is just what I was looking for. thanks, Sam
2012/1/14 Jay Fields <[email protected]> > this seems easier... > > user=> (map str "abc") > ("a" "b" "c") > > Though the original question says a list to a string and the example shows > a string to a list (of symbols) > > user=> (apply str ["a" "b" "c"]) > "abc' > > But, the example is looks like it wants > > user=> (map (comp symbol str) "abc") > (a b c) > > Hopefully one of those is what you're looking for. > > Cheers, Jay > > On Jan 14, 2012, at 1:01 PM, dennis zhuang wrote: > > You can do this > > ((comp #(map str %) seq) "abcdef") > ("a" "b" "c" "d" "e" "f") > > 2012/1/15 Bruce Durling <[email protected]> > >> Sam, >> >> Strings can be turned into sequences with seq. >> >> > (seq "foo") >> (\f \o \o) >> >> The backslashes are because f o and o are character literals. >> >> cheers, >> Bruce >> >> On Sat, Jan 14, 2012 at 10:13, Samuel Lê <[email protected]> wrote: >> > Hi, >> > >> > I was wondering if there was a function to convert a list into a string, >> > something like: >> > (string-to-list "abcde") ;; (a b c d e) >> > >> > thanks! >> > >> > Sam >> > >> > -- >> > You received this message because you are subscribed to the Google >> > Groups "Clojure" group. >> > To post to this group, send email to [email protected] >> > Note that posts from new members are moderated - please be patient with >> your >> > first post. >> > To unsubscribe from this group, send email to >> > [email protected] >> > For more options, visit this group at >> > http://groups.google.com/group/clojure?hl=en >> >> -- >> You received this message because you are subscribed to the Google >> Groups "Clojure" group. >> To post to this group, send email to [email protected] >> Note that posts from new members are moderated - please be patient with >> your first post. >> To unsubscribe from this group, send email to >> [email protected] >> For more options, visit this group at >> http://groups.google.com/group/clojure?hl=en >> > > > > -- > 庄晓丹 > Email: [email protected] > 伯岩(花名) [email protected] > Site: http://fnil.net > > 淘宝(中国)软件有限公司 / 产品技术部 / Java中间件 > > > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to [email protected] > Note that posts from new members are moderated - please be patient with > your first post. > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en > > > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to [email protected] > Note that posts from new members are moderated - please be patient with > your first post. > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to [email protected] Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/clojure?hl=en
