For this Question: Numbers are awesome, the xor of them is more.
You are given an array A of N natural numbers. For each A[i], you need to find the Xor Value, A[i]^A[i+1]^A[i+2]^...^A[n].
Find the sum of Xor values for each element A[i].The first line of the input contains an integer N denoting the number of elements in the array.
The next line contains N single spaced integers.

<b>Constraints</b>
1 <= N <= 100000
1 <= A[i] <= 1000000000Output the single integer, the sum of Xor values for each element in array.
Note:-you may need to use long longSample Input 
5
1 2 3 4 5

Sample Output
9

<b>Explanation</b>
Xor values are as follows: 1, 0, 2, 1, 5 and their  sum is 9, I have written this Solution Code: n = int(input())
arr = list(map(int,input().split()))
xor = 0
result = 0
for i in range(n-1,-1,-1):
	xor = xor^arr[i]
	# print(xor)
	result += xor
print(result), In this Programming Language: Python, Now tell me if this Code is compilable or not?