2019年12月15日 星期日

C# equivalent to Java's charAt()?

https://stackoverflow.com/questions/3581741/c-sharp-equivalent-to-javas-charat

You can index into a string in C# like an array, and you get the character at that index.
Example:
In Java, you would say
str.charAt(8);
In C#, you would say
str[8];

C# String charAt

沒有留言:

張貼留言