using System; public class Test { public static void Main() { string str = "20.222"; Console.WriteLine(str); int index = str.IndexOf('.'); if (index > -1) { Console.WriteLine(index); Console.WriteLine(str.Length-1); char[] ch = str.ToCharArray(index + 1, str.Length - index -1); foreach(char c in ch) { Console.WriteLine(c); } } } }