public static void InsertSortedListMain() { var list = ListBuilder.Create(new[] { 2, 5, 7, 10, 15 }); var inserted = InsertValue(list, 16); ListBuilder.Dump(inserted); }
public static void ReverseListMain() { var list = ListBuilder.Create(new[] { 1, 2, 3 }); //1 3->2->null var reverse = Reverse(list); }
public static void LinkedListReversalMain() { var reversed = Reverse(ListBuilder.Create(new[] { 1, 2, 3, 4, 5 })); ListBuilder.Dump(reversed); }