Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
private static void LastDemo(List<Order> orders)
var lastOrderAfterMarch = orders.Last(order => order.OrderDate >= march);
PrintHeaderFooter("Last order after March", () => PrintOrder(lastOrderAfterMarch, indentBy), indentBy);
var LastOrderAfterSeptember = orders.LastOrDefault(order => order.OrderDate >= september);
PrintHeaderFooter("Last or Default order after September", () => PrintOrder(LastOrderAfterSeptember, indentBy), indentBy);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.