For this Question: Given an array of size 2*N in the form as [x1, x2.. xn, y1, y2,. yn], your task is to shuffle the array in the form given as [x1, y1, x2, y2,. xN, yN]First line of input contains a single integer N. Next line of input contains 2*N space separated integers depicting the values of the array.

Constraints:-
1 <= N <= 10000
1 <= Arr[i] <= 100000Print the shuffled array.Sample Input:-
3
1 2 3 4 5 6

Sample Output:-
1 4 2 5 3 6

Sample Input:-
2
2 4 6 8

Sample Output:-
2 6 4 8, I have written this Solution Code: 
import java.util.*;
import java.lang.*;
import java.io.*;

class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
		Scanner sc = new Scanner(System.in);
	    
		int n = sc.nextInt();
		int a[] = new int[2*n];
		int j=0;
		for(int i=0;i<2*n;i++){
		    a[j]=sc.nextInt();
		    j+=2;
		    if(j>=2*n){
		        j=1;
		        
		    }
		}
		for(int i=0;i<2*n;i++){
		    System.out.print(a[i]+" ");
		}


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