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: import java.io.*;
import java.util.*;



class Main {
	public static void main (String[] args)throws IOException {

		 BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
         int n=Integer.parseInt(br.readLine());
		 int a[]=new int[n];
		 int b=0;
		 int i=0;
		 long c=0;
		 String s[]=br.readLine().split(" ");
		 for(int k=0;k<n;k++){
           a[k]=Integer.parseInt(s[k]);

           }

		  while(i<n){
			  int j=i;
			  while(j<n){
				 b=b ^a[j];
				  j++;
			  }
			  c +=b;
			  b=0;
			  i++;
		  }
		  System.out.print(c);
	}
}, In this Programming Language: Java, Now tell me if this Code is compilable or not?