0
comment
comment
on 4/8/2014 8:49 AM
This post is the answer to yesterday's brainteaser. As a reminder, I was asking what purpose this code might have: public static class Extensions { public static void Add<T>(this ICollection<T> source, T item) { source.Add(item); } } There are plenty of answers, varying from completely incorrect (sorry!) to pretty much spot on. As many people noticed, ICollection<T> already has an Add method taking an item of type T. So what difference could this make? Well, consider LinkedLis[...]