Im trying to take a string of characters check if any of the charachters in that string are lowercased, if that is the case I want to change them, but when im trying to use Char.ToLower() nothing happens.
Console.Clear();
string rightWord = "Arose";
//making all letters into small letters
//making a array of the right word
char[] rightWordArray = rightWord.ToCharArray();
for (int i = 0; i < rightWord.Length; i++)
{
if (char.IsUpper(rightWordArray[i]))
{
char.ToLower(rightWordArray[i]);
}
}
//writing out all chars in rightWordArray
foreach (var item in rightWordArray)
{
Console.WriteLine(item);
}
I have tried String.ToLower too but it doesent work.
Per UnholySheep's comment: