C#List集快速拼接一个字符串
原创List list = new List();
list.Add("拼");
list.Add("接");
//Join方法的第一个参数为分割符
string str = string.Join("",list.ToArray());
//第一个参数为"",str的值就为"拼接"
//第一个参数为"——",str的值就为"拼——接"
简单实用的一个自带方法,一行代码搞定,for或foreach在它面前都比较臃肿了,哈哈哈。
版权声明
所有资源都来源于爬虫采集,如有侵权请联系我们,我们将立即删除
相关文章
最新文章
- Backd:用社区投票替代融资背书的创业项目发现平台,能走多远? 50分钟前
- iPhone隐私不比Android强?牛津大学研究打破苹果安全神话 51分钟前
- Show HN: Dadgpt Open Source Halloween Costume 53分钟前
- Retroviral insertions contributed to divergence of human and chimpanzee brains 55分钟前
- Implications of Large-Scale Test-Time Compute 2小时前
- UK government sets out $800M of AI security funding 2小时前
- Xbox Turns Down Netflix $500M Offer 2小时前
- Show HN: Close the UI building AI agent loop with Protoshot 2小时前
- BBC interview with Ondřej Surý, Debian/Ubuntu PHP package maintainer 3小时前
- Talking with strangers is surprisingly informative 3小时前
itfan123

