摘要: 1 class Zipper { 2 public: 3 string zipString(string iniString) { 4 // write code here 5 string out; 6 char ch=iniString[0]; 7 int n = 0; 8 for(int i= 阅读全文
posted @ 2016-07-23 22:56 Pearl_zju 阅读(189) 评论(0) 推荐(0) 编辑
摘要: 1 class Replacement { 2 public: 3 string replaceSpace(string iniString, int length) { 4 // write code here 5 for(int m=0;m<iniString.size();) 6 { 7 in 阅读全文
posted @ 2016-07-23 21:47 Pearl_zju 阅读(160) 评论(0) 推荐(0) 编辑
摘要: 方法1 方法2 阅读全文
posted @ 2016-07-23 21:23 Pearl_zju 阅读(169) 评论(0) 推荐(0) 编辑
摘要: 1 class Reverse { 2 public: 3 string reverseString(string iniString) { 4 // write code here 5 string::iterator b=iniString.begin(); 6 string::iterator 阅读全文
posted @ 2016-07-23 21:21 Pearl_zju 阅读(212) 评论(0) 推荐(0) 编辑
摘要: 1 class Different { 2 public: 3 bool checkDifferent(string iniString) { 4 // write code here 5 int len=iniString.size(); 6 if(len>256) 7 return false; 阅读全文
posted @ 2016-07-23 21:19 Pearl_zju 阅读(237) 评论(0) 推荐(0) 编辑