4thSpace 4thSpace - 3 months ago 8
C# Question

What is character index returning?

When I do the following:

"123c"[3]


The returned value is
99 'c'
.

How do I get only the character
c
?

Answer

The value is still just a char = c. 99 is just its ASCII value. It only shows in the debugger (i.e. "Autos"/"Locals", watches, etc.).