• + 0 comments

    Using Python :

    def larrysArray(A): # Write your code here c=0 for i in range(0,len(A)-1): for j in range(i,len(A)): if(A[i]>A[j]): c+=1 if(c%2==0): return "YES" else: return "NO"