string:join ?
Valentin
valentin@REDACTED
Fri Jun 11 12:10:24 CEST 2004
So what is wrong with:
lists:concat( ["Hello", " ", "World"] ).
or if you insist:
lists"concat( ["Foo", " ", "Bar", " ", "Bazz"]).
Seriously, what am I missing here?
V.
----- Original Message -----
From: "David N. Welton" <davidw@REDACTED>
To: <erlang-questions@REDACTED>
Sent: Friday, June 11, 2004 10:20 AM
Subject: Re: string:join ?
> Per Hedeland wrote:
> > "Robert Virding" <robert.virding@REDACTED> wrote:
> >
> >>What is string:join supposed to do? If it just a simple concatenation of
two
> >>strings then S1 ++ S2 well defined and efficient.
>
> > 'man perlfunc' (ducking:-)
>
> Joking aside, I've used scripting languages a lot in the past, and they
> all have some form of string join that, yes, more or less behaves like
> the one Perl provides:
>
> I have: ["Foo", "Bar", "Baz"]
>
> I want: "Foo Bar Baz"
>
> (I might also want to join them with something besides a blank space).
>
> > Or at least that's what I assume...
>
> Yes, it has been duly pointed out several times to me in private that I
> neglected to state clearly what I wanted:-)
>
> > (And I agree that it's "missing".:-)
>
> It's a handy feature to have when working with strings.
>
> Thanks,
> --
> David N. Welton
> davidw@REDACTED
More information about the erlang-questions
mailing list