For this Question: We need a problem on xor again. Given an array A of N integers (1- indexed), you need to find the sum of (N- i) xor A[i] for all i from 1 to N.The first line of the input contains an integer N, the number of elements of the array.
The second line of the input contains N singly spaced integers of the array A[i].

<b>Constraints:</b>
1 &le; N &le; 10<sup>5</sup>
1 &le; A[i] &le; 10<sup>9</sup>Output a single integer, the answer to the problem.Sample Input
5
1 2 3 4 5

Sample Output
17

Explanation
(5-1)xor1 = 5, (5-2)xor2 = 1, (5-3)xor3 = 1, (5-4)xor4 = 5, (5-5)xor5 = 5.

Sample Input
5
1 1 0 4 6 

Sample Output
20, I have written this Solution Code: import java.io.*;
import java.util.*;

class Main {

	void xorOps(int n, long[] input){
		long res=0;

		for(int i=0;i<n;i++){
			long temp = (n-(i+1))^(input[i]);
			res=res+temp;
		}
		System.out.print(res);
	}
	public static void main (String[] args)throws java.lang.Exception {

		Main obj = new Main();

		BufferedReader br = new BufferedReader(new InputStreamReader
										(System.in));
		int n = Integer.parseInt(br.readLine());

		String[] raw_input= br.readLine().split(" ");
		long[] input = new long[n];

		for(int i=0; i<n;i++){
			input[i]=Long.parseLong(raw_input[i]);
		}


		obj.xorOps(n,input);

	}
}, In this Programming Language: Java, Now tell me if this Code is compilable or not?