Mr-Robot

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2017年1月19日

摘要: 一、字符串转换为字符数组 char[] tempChar = sourceString.ToCharArray(); 二、字符数组转换为字符串 //方法一string str = string.Join("", tempChar);//方法二string str = string.Concat(... 阅读全文
posted @ 2017-01-19 11:08 代码养家 阅读(1418) 评论(0) 推荐(1)

摘要: 方法中也提供了一种由字符数组转换为字符串的方法。 /// /// 使用指定的字符替换除首尾字符外的字符串中的字符 /// /// 原字符串 /// 指定的字符 /// private static string ReplaceWithNewStr(string sourceSt... 阅读全文
posted @ 2017-01-19 10:50 代码养家 阅读(317) 评论(0) 推荐(0)