in reply to Re: extract text between slashes
in thread extract text between slashes

print join ', ', @strings, "\n";

I'm not sure whether you intended a trailing ', ' in the output. If not, you could use parentheses

print join(', ', @strings), "\n";

I might instead tinker with the list separator

print do { local $" = q{, }; qq{@strings\n}; };

Cheers,

JohnGG

Replies are listed 'Best First'.
Re^3: extract text between slashes
by mwah (Hermit) on Oct 31, 2007 at 20:10 UTC
    I'm not sure whether you intended a trailing ', ' in the output. If not, you could use parentheses

    .oO you got me ...

    If I'd say now "I didn't care if a trailing comma would show up" nobody would believe me. If I'd say "I tried to make the output of print "@strings\n"; more distinct for a beginner", the same would happen.

    Therefore the best would be to take the blame and admit failure ;-)

    Thanks & Regards

    mwa