public void Four_Layer() { var actual = PascalTriangle.CalcualteLayer(4); CollectionAssert.AreEqual(new List <int> { 1, 1, 1, 1, 2, 1, 1, 3, 3, 1 }, actual); }
public void Six_Layer() { var actual = PascalTriangle.CalcualteLayer(6); CollectionAssert.AreEqual(new List <int> { 1, 1, 1, 1, 2, 1, 1, 3, 3, 1, 1, 4, 6, 4, 1, 1, 5, 10, 10, 5, 1 }, actual); }
public void One_Layer() { var actual = PascalTriangle.CalcualteLayer(1); CollectionAssert.AreEqual(new List <int> { 1 }, actual); }