String.Split的对面有隔板(.NET) [英] Opposite of String.Split with separators (.net)
本文介绍了String.Split的对面有隔板(.NET)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有没有办法做到String.Split相反在.net中?即,到阵列的所有元素结合给定的隔板。
Is there a way to do the opposite of String.Split in .Net? That is, to combine all the elements of an array with a given separator.
以[一个,B,C],并给予ABC(以分隔符)。
Taking ["a", "b", "c"] and giving "a b c" (with a separator of " ").
更新:我发现自己的答案。这是的string.join
方法。
UPDATE: I found the answer myself. It is the String.Join
method.
推荐答案
找到了答案。这就是所谓的<一个href="http://msdn.microsoft.com/en-us/library/System.String.Join%28v=vs.110%29.aspx">String.Join.
Found the answer. It's called String.Join.
这篇关于String.Split的对面有隔板(.NET)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文