C# Corner
Tech
News
Videos
Forums
Jobs
Books
Events
More
Interviews
Live
Learn
Training
Career
Members
Blogs
Challenges
Certification
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Refer
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
Count Occurrences of a Character in a String using LINQ
WhatsApp
Shinuraj
14y
14.9
k
0
0
25
Blog
try out the below code!
Dim
testString
As
String
=
"this is for testing the linq query."
Dim
count
As
Integer
= (
From
s
In
testString.ToCharArray
Where
s =
"i"
Select
s).Count
thanks
-Shinu
Count Occurrences of a Character in a String using LINQ
People also reading
Membership not found