This is something I have been confused with for quite a while now. Not sure if it's a C# specific problem or some simple OOP fact I am not able to grasp.
IList<IList<int>> result = new List<IList<int>>(); //Works Fine
IList<IList<int>> result2 = new IList<IList<int>>(); //Gives Error because we cannot initialize interface
IList<IList<int>> result3 = new List<List<int>>(); //Gives Error please explain why
IList<IList<int>> result4 = new IList<List<int>>(); //Gives Error please explain why
For the above lines of code can someone please explain why line 3 and 4 are wrong and line 1 is right?