public void Strings6() { var list = FList.New("Tom", "Dick", "Harry"); var expected = FList.New('o', 'm'); Assert.AreEqual(expected, FList.Tail(FList.Head(list))); }
public void Strings7() { var str = "Harry"; var expected = 'H'; Assert.AreEqual(expected, FList.Head(str)); }
public void Strings3() { var list = FList.AsChars("Tom"); var expected = 'T'; Assert.AreEqual(expected, FList.Head(list)); }
public void Strings5() { var list = FList.New("Tom", "Dick", "Harry"); var expected = 'T'; Assert.AreEqual(expected, FList.Head(FList.Head(list))); }
public void Head1() { var list = FList.New(1, 2, 3, 4, 5); var actual = FList.Head(list); var expected = 1; Assert.AreEqual(expected, actual); }
public void Head1String() { var list = "12345"; var actual = FList.Head(list); var expected = '1'; Assert.AreEqual(expected, actual); }
public void Head2() { var list = FList.New(5); var actual = FList.Head(list); var expected = 5; Assert.AreEqual(expected, actual); }
public void Head3Action() { var list = FList.Empty <int>(); var actual = FList.Head(list); }
public void Strings1() { var list = FList.New("Tom", "Dick", "Harry"); Assert.AreEqual("Tom", FList.Head(list)); }
public static string PartialFeynmanDiagram(FList <string> List) { return(FList.Length(List) == 1 ? FList.Head(List) : FList.Head(List) + " + " + PartialFeynmanDiagram(FList.Tail(List))); }