Finished the isDescending function.