
    Write a function to determine if a student's academic performance trend is consistently increasing or decreasing by analyzing their sequential grade scores or attendance rates across terms. A trend is considered consistent if all numbers in the sequence are either non-increasing or non-decreasing throughout the entire period.
    

    
def is_Monotonic(A):
    """
    Write a function to determine if a student's academic performance trend is consistently increasing or decreasing by analyzing their sequential grade scores or attendance rates across terms. A trend is considered consistent if all numbers in the sequence are either non-increasing or non-decreasing throughout the entire period.
    

    """
def is_Monotonic(A):
    """
    Write a function to determine if a student's academic performance trend is consistently increasing or decreasing by analyzing their sequential grade scores or attendance rates across terms. A trend is considered consistent if all numbers in the sequence are either non-increasing or non-decreasing throughout the entire period.
    

    """
    return all((A[i] <= A[i + 1] for i in range(len(A) - 1))) or all((A[i] >= A[i + 1] for i in range(len(A) - 1)))