Set the boolean b to true if the list items has all its elements in increasing order, false otherwise.The order is not strict: the ordered list may contain duplicate elements.
import "slices"
b := slices.IsSorted(items)
classes
b := items.sorted and (items.count > 1) and (items[0] < items[1]);
b = sorted(items) == items
b = items.each_cons(2).all?{ _1 <= _2 }
b = items.each_cons(2).all?{|a,b| a <= b }
No security, no password. Other people might choose the same nickname.