using System; class MainClass { public static void Main() { string str = "This is a test. $23"; int i; for(i=0; i < str.Length; i++) { Console.Write(str[i] + " is"); if(Char.IsLower(str[i])) Console.Write(" lowercase"); if(Char.IsUpper(str[i])) Console.Write(" uppercase"); Console.WriteLine(); } } }
T is uppercase h is lowercase i is lowercase s is lowercase is i is lowercase s is lowercase is a is lowercase is t is lowercase e is lowercase s is lowercase t is lowercase . is is $ is 2 is 3 is