Start with an empty vector, say v. conj your strings to the vector at the various points in your code, so at the end v will be something like ["this" "is" "a" "string"] Then, when you're done, apply str to the vector, i.e., (apply str v) to get "thisisastring"
str uses a string builder behind the scenes, so it's efficient this way. If you keep applying str at each point in your code, it won't be. On Wed, Sep 29, 2010 at 7:48 PM, HiHeelHottie <hiheelhot...@gmail.com> wrote: > > Is there an idiomatic way to build up a string over different lines of > code? Or, should one simply use StringBuilder. > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en