当前位置:网站首页>C#Split的用法,Split分割字符串
C#Split的用法,Split分割字符串
2022-07-23 16:36:00 【HappyGirl快乐女孩】
分割单个字串:
string str="来自张三的亲切问候!;
string[] strarry=str.Split(new string[] { "张三" }, StringSplitOptions.None);
分割结果:["来自","的亲切问候!"]分割单个字符:
string s="aaBBcdefgh;
string[] sArray=s.Split('c') ;
分割结果:["aaBB","defgh"]分割多个单个字符:
tring s="abcdeabcdeabcde";
string[] sArray1=s.Split(new char[3]{'c','d','e'});
输出下面的结果:ab ab ab边栏推荐
- What problems do you usually encounter when learning 3D modeling? It's too much
- 【2020】【论文笔记】基于二维光子晶体的光控分光比可调Y——
- Problems and methods of creating multiple projects under one solution in VS2010
- 【ONNX】动态输入尺寸的问题(多输出/多输入)
- Analysis on the implementation of Flink exactly once delivery
- Block encryption mode ECB, CBC, PCBC, CFB, OFB, CTR
- 如何理解:普通代码块、构造块、静态块?有什么关系?
- How does the NiO mechanism of jetty server cause out of heap memory overflow
- 关于分组查询的一道sql题
- 世界上最大的开源基金会 Apache 是如何运作的?
猜你喜欢

UAV circulating an unknown target under a GPS deniedenvironment with range only measurements translation

【重磅】聚焦券商终端业务,博睿数据发布新一代券商终端核心业务体验可观测平台

建模刚学习很迷茫,次世代角色建模流程具体该怎么学习?

【攻防世界WEB】难度四星12分进阶题:Cat

类的基础
![Multithreading [comprehensive study of graphics and text]](/img/70/8a1227b2159349cf25a85dff8f9d1c.png)
Multithreading [comprehensive study of graphics and text]

Google正在改进所有产品中的肤色表现 践行“图像公平”理念

Modeling just learning is very confused. How to learn the next generation role modeling process?
![[toggle 30 days of ML] Diabetes genetic risk detection challenge (2)](/img/39/d0134a8493877beaa6b6850c045f2b.png)
[toggle 30 days of ML] Diabetes genetic risk detection challenge (2)

Can self-study 3D modeling succeed? Can self-study lead to employment?
随机推荐
Flink Exactly-Once 投递实现浅析
PCL:多直线拟合(RANSAC)
How to become a modeler? Which is more popular, industrial modeling or game modeling?
[sharing 3D modeling and production skills] how ZBrush turns pictures into relief models
Redis [2022 latest interview question]
【游戏建模模型制作技巧分享】ZBrush如何调整笔刷大小
《通信软件开发与应用》课程结业报告
[whole process of game modeling model production] 3ds Max and ZBrush produce radio receivers
BOM系列之BOM介绍
LM393低功耗双电压比较器参数、引脚、应用详解
零基础要学建模该从何开始?如何才能学好游戏建模?
Leetcode sword finger offer II 115. reconstruction sequence: diagram topology sorting
SQLZOO——BBC QUIZ
Redis【超强超细 入门教程】
[easy to understand] relational schema paradigm decomposition tutorial 3NF and BCNF formula! Xiaobai can also understand "suggestions collection"
银行业如何实现数字化转型风口全速启航
自学3D建模能不能成功?自学能就业吗?
有人是靠自学建模找到工作的吗?千万别让这些思维害了你
Block encryption mode ECB, CBC, PCBC, CFB, OFB, CTR
398. 随机数索引-哈希表法