def is_sorted(lst):
    """Checks whether the input list is sorted."""

    for i in range(len(lst) - 1):
        if lst[i] > lst[i + 1]:
            print(lst)
            return False
    return True