For this Question: You are given an array of integers of length N, where N is even.

You need to split the array into two parts of equal size in such a way that the difference between the sums of the parts is maximised. The sum of a part is defined as the sum of the elements it contains.

Note that each element of the original array <b>must be in exactly one of the parts</b>.

Print the maximum possible difference.The first line of the input contains a single integer N (2 <= N <= 10<sup>4</sup>, N is even).
The second line of the input contains N space separated integers, the elements of the original array. Each element is within the range 0 to 10<sup>4</sup> inclusive.Print a single integer, the required maximum difference.Sample Input:
4
3 5 1 4

Sample Output:
5

Explanation:
It is optimal to make 2 parts as -- {4, 5} and {3, 1}., I have written this Solution Code: n = int(input())
elements = input()
array = str.split(elements)
for i in range(len(array)):
    array[i] = int(array[i])
array.sort()
sum1 = 0
sum2 = 0
for x in range(int(n/2)):
    sum1 += array[x]
for x in range(int(n/2)):
    sum2 += array[x+int((n/2))]
diff = sum2 - sum1
print(diff), In this Programming Language: Python, Now tell me if this Code is compilable or not?