Skip to main content

All Questions

Filter by
Sorted by
Tagged with
3 votes
2 answers
723 views

Smartly joining possibly empty strings

I want to join two fragments into one string with a separator, but when one of the fragments is empty I only want one of them. I have two implementations. The first is long and slightly repetitive, ...
schuelermine's user avatar