VBS去除指定的字符串中的重复项返回重复后的字符串
2012-04-08 11:53
232 查看
sub replaceComon(str) for i=1 to len(str) tempstr=mid(str,i,1) finalstr="" if instr(1,finalstr,tempstr,1)>0 then '查找到了重复的字符 str=replace(str,tempstr,"") else '没有查找到重复的字符的时候就追加字符到新字符串中 finalstr=finalstr+tempstr end if next replaceComon=finalstr end sub
.csharpcode, .csharpcode pre
{
font-size: small;
color: black;
font-family: consolas, "Courier New", courier, monospace;
background-color: #ffffff;
/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt
{
background-color: #f4f4f4;
width: 100%;
margin: 0em;
}
.csharpcode .lnum { color: #606060; }
相关文章推荐
- VBS去除字符串的重复项并统计重复字符出现的次数
- 猫猫学iOS之去除服务器返回数据中的html标签,去除指定字符串,替换字符串
- AJ学IOS之去除服务器返回数据中的html标签,去除指定字符串,替换字符串
- 返回字符串中的所有单词 $distinct=true 去除重复
- 写一个函数,用来把一个字符串用指定的字符作为分隔符分割成若干个子串输出 | 写一个函数,用来返回一个字符串中重复出现的最长字串的长度及其开始地址
- String函数:返回指定长度重复字符组成的字符串
- JS实现字符串中去除指定子字符串方法分析
- delphi中按指定字符重复生成指定长度字符串
- Oracle数据库存储过程 ,去除给定字符串中重复的字符串
- SqlServer:根据指定分隔符,把传入字符串分隔处理后,返回数据表,函数功能类似.NET的string.Split()
- 详解JavaScript数组和字符串中去除重复值的方法
- 分割字符串到数组/替换字符串/返回指定字节长度的字符串/判断是否为浮点数,包括double和float/email判断/是否纯汉字判断/空白判断
- js生成指定范围内指定长度随机不重复的字符串数组
- 1.删除字符串中重复的字符 2.删除字符串中指定的字符串 3.删除数组中重复元素
- 去除字符串重复数据 分类: python基础学习 2013-08-08 17:44 335人阅读 评论(0) 收藏
- 如何查找一个字符串中重复次数最多的字符,返回这个字符的个数和字符
- 去除重复字符串
- java去除重复字符串
- ArrayList去除集合中字符串的重复值
- 去除字符串头尾的指定字符