using System.Collections.Generic;
public static void Main()
List<double> list = new List<double>()
2.7, -3.5, 0.6, 34.83, 7.458, 0, 9.20, -20.40, 12.2
for(int i = 0; i < list.Count; ++i)
if((list[i] % 1) == 0) continue;
string nrstring = list[i].ToString();
string aftercomma = nrstring.Split('.')[1];
if(aftercomma.Length > digits)
digits = aftercomma.Length;