can someone help me check my codes if are right or help me know if there is any other is way to solve this question I was trying to check if an array is in ascending or desc