ratty ratty - 2 years ago 2004
Java Question

C# equivalent to Java's charAt()?

I know we can use the

method in Java get an individual character in a string by specifying its position. Is there an equivalent method in C#?

Answer Source

You can index into a string in C# like an array, and you get the character at that index.


In Java, you would say


In C#, you would say

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download