1# To sort the list in place...
2ut.sort(key=lambda x: x.count, reverse=True)
3
4# To return a new list, use the sorted() built-in function...
5newlist = sorted(ut, key=lambda x: x.count, reverse=True)
1objListOrder.Sort((x, y) => x.OrderDate.CompareTo(y.OrderDate));
2// or
3bomPositionsList.Sort((oneItem, otherItem) => string.Compare(oneItem.ArticleGroup, otherItem.ArticleGroup, StringComparison.Ordinal));
4