Arrays are said to be equal if and only if both arrays contain the same elements and the frequencies of each element in both arrays are the same.
Input: arr1[] = {1, 2, 3, 4, 5}, arr2[] = {5, 4, 3, 2, 1}
Output : Equal
Explanation: As both the arrays contain same elements.
Arrays are said to be equal if and only if both arrays contain the same elements and the frequencies of each element in both arrays are the same.
Examples: