9
Imagine I have the following string:
string texto = "Stackoverflow em Português";
If I want to know the index of the first space, just:
int index = texto.IndexOf(" ");
But in this case I have two spaces, and would like to get the index of the last.
It is necessary to consider that the string may have more spaces. The goal is to always get the last.
There is something ready in C# that does this?