using System; using System.Collections.Generic; public class Test{ public static void Main(){ var ls = new LinkedList(); for(int i=0; i<10; i++){ls.AddFirst(""+(char)('A'+i));} f(ls); } static void f(ICollection c){ f(c, c.Count); } static void f(IEnumerable c, int cnt){ int ix=1; foreach(T et in c){ Console.WriteLine("({0,3}% : {1}/{2}) {3}", ix*100/cnt, ix, cnt, et); ix++; } } }