For this Question: A basic queue has the following operations:

Enqueue: add a new element to the end of the queue.
Dequeue: remove the element from the front of the queue and return it.
In this challenge, you must first implement a queue using two stacks. Then process q queries, where each query is one of the following 3 types:

1 x: Enqueue element x into the end of the queue.
2: Dequeue the element at the front of the queue.
3: Print the element at the front of the queue.<b>User task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the functions:-
<b>enQueue()</b> that takes the integer x(input element) as a parameter.
<b>deQueue()</b>that takes no parameter
<b>Print1()</b>that print the element which is at the front of the queue

Constraints:-
1 <= x <= 10^9
1 <= number of queries <= 1000

Note:- It is guaranteed that the queue will never be empty whenever Print function or deQueue function is called.Print the value of the element which is at the front of the queue on a new line in Print1().Sample Input:-
10
1 42
2
1 14
3
1 28
3
1 60
1 78
2
2


Sample Output:-
14
14, I have written this Solution Code: 
  
    static void enQueue(int x)  
    {  
        // Move all elements from s1 to s2  
        while (!s1.isEmpty()) 
        {  
            s2.push(s1.pop());  
            //s1.pop();  
        }  
  
        // Push item into s1  
        s1.push(x);  
  
        // Push everything back to s1  
        while (!s2.isEmpty())  
        {  
            s1.push(s2.pop());  
            //s2.pop();  
        }  
    }  
  
    // Dequeue an item from the queue  
    static void deQueue()  
    {  
        // if first stack is empty  
        if (s1.isEmpty())  
        {  
            System.out.println("Q is Empty");  
            System.exit(0);  
        }  
  
        // Return top of s1  
        int x = s1.peek();  
        s1.pop();  
    } 
    static void Print1(){
        int x=s1.peek();
        System.out.println(x);
    }
, In this Programming Language: Java, Now tell me if this Code is compilable or not?