lisa.utils.is_monotonic#

lisa.utils.is_monotonic(iterable, decreasing=False)[source]#

Return True if the given sequence is monotonic, False otherwise.

Parameters:

decreasing (bool) – If True, check that the sequence is decreasing rather than increasing.