For this Question: Given an array of N elements, N is an even positive number. You have to make N/2 pairs among them such that each element is in exactly one pair. Score of a pair is the absolute difference between there values. Find the maximum sum of score of N/2 pairs.First Line of input contains N.
Second line of input contains N space seperated integers, denoting Arr.

Constraints:
1 <= N <= 100000
1 <= Arr[i] <= 1000000000
N will be evenPrint a single integer which is the maximum sum of score of N/2 pairs.Sample Input 1
2
1 2

Sample Output 1
1

Sample Input 2
4
1 4 2 4

Sample Output 2
5

Explanation: (1, 4) (2, 4) are the optimal pairs, I have written this Solution Code: n = int(input())
arr = list(map(int,input().split()))

arr.sort()
s = 0
for i in range(n//2):
	s += arr[n-i-1]-arr[i]

print(s), In this Programming Language: Python, Now tell me if this Code is compilable or not?