Problem: You are given an array a of n integers.

You want to make all elements of a equal to zero by doing the following operation exactly three times:

  * Select a segment, for each number in this segment we can add a multiple of len to it, where len is the length of this segment (added integers can be different). 



It can be proven that it is always possible to make all elements of a equal to zero.

Input

The first line contains one integer n (1 ≤ n ≤ 100 000): the number of elements of the array.

The second line contains n elements of an array a separated by spaces: a_1, a_2, ..., a_n (-10^9 ≤ a_i ≤ 10^9).

Output

The output should contain six lines representing three operations.

For each operation, print two lines:

  * The first line contains two integers l, r (1 ≤ l ≤ r ≤ n): the bounds of the selected segment.

  * The second line contains r-l+1 integers b_l, b_{l+1}, ..., b_r (-10^{18} ≤ b_i ≤ 10^{18}): the numbers to add to a_l, a_{l+1}, …, a_r, respectively; b_i should be divisible by r - l + 1.

Example

Input


4
1 3 2 4


Output


1 1 
-1
3 4
4 2
2 4
-3 -6 -6

Solution (in JAVA):

Solution:

import java.io.*;
import java.util.*;
import java.math.*;
import java.math.BigInteger;
public final class codeForces
{    
    public static void main(String args[])
    {
        StringBuilder ans=new StringBuilder();
        FastReader in=new FastReader();  
        int N=in.nextInt();
        long A[]=new long[N+1];
        for(int i=1; i<=N; i++)
            A[i]=in.nextInt();
        if(N>1)
        {

            ans.append(1+" "+(N-1)+"\n");
            for(int i=1; i<=N-1; i++)
            {
                int x=N-1;
                if(A[i]%x==0)
                {
                    ans.append(-A[i]+" ");
                    A[i]=0;

                }
                else
                {
                    ans.append(A[i]*x+" ");
                    A[i]+=A[i]*x;

                }
            }ans.append("\n");
            ans.append(1+" "+N+"\n");
            for(int i=1; i<N; i++)
            {
                ans.append(-A[i]+" ");

            }
            ans.append(0+"\n");
            ans.append(N+" "+N+"\n");
            ans.append(-A[N]);
        }
        else
        {
            System.out.println(1+ " "+1);
            System.out.println(0);
            System.out.println(1+ " "+1);
            System.out.println(0);
            System.out.println(1+ " "+1);
            System.out.println(-A[1]);

        }
        System.out.println(ans);
    }
    //fucntions
    //fucntions
    //fucntions
    //fucntions
    static int[] input(int A[]) //input of Int Array
    {
        FastReader in=new FastReader();
        int N=A.length;
        for(int i=0; i<N; i++)
        {
            A[i]=in.nextInt();
        }
        return A;
    }

    static long[] input(long A[]) //Input of long Array
    {
        FastReader in=new FastReader();
        for(int i=0; i<A.length; i++)A[i]=in.nextLong();
        return A;
    }

    static int GCD(int a,int b) //wrong output if a ||b are intially zero
    {
        if(b==0)
        {
            return a;
        }
        else return GCD(b,a%b );
    }

    static boolean isPrime(int N)
    {
        for(int i=2; i*i<N; i++)
            if(N%i==0)return false;
        return true;
    }

}
//Code For FastReader
//Code For FastReader
//Code For FastReader
//Code For FastReader
class FastReader
{
    BufferedReader br;
    StringTokenizer st;
    public FastReader()
    {
        br=new BufferedReader(new InputStreamReader(System.in));
    }

    String next()
    {
        while(st==null || !st.hasMoreElements())
        {
            try
            {
                st=new StringTokenizer(br.readLine());
            }
            catch(IOException e)
            {
                e.printStackTrace();
            }
        }
        return st.nextToken();
    }

    int nextInt()
    {
        return Integer.parseInt(next());
    }

    long nextLong()
    {
        return Long.parseLong(next());
    }

    double nextDouble()
    {
        return Double.parseDouble(next());
    }

    String nextLine()
    {
        String str="";
        try
        {
            str=br.readLine();
        }
        catch (IOException e)
        {
            e.printStackTrace();
        }
        return str;
    }

}
//code For Reader CLass
/*
class Reader 
{ 
final private int BUFFER_SIZE = 1 << 16; 
private DataInputStream din; 
private byte[] buffer; 
private int bufferPointer, bytesRead; 

public Reader() 
{ 
din = new DataInputStream(System.in); 
buffer = new byte[BUFFER_SIZE]; 
bufferPointer = bytesRead = 0; 
} 

public Reader(String file_name) throws IOException 
{ 
din = new DataInputStream(new FileInputStream(file_name)); 
buffer = new byte[BUFFER_SIZE]; 
bufferPointer = bytesRead = 0; 
} 

public String readLine() throws IOException 
{ 
byte[] buf = new byte[64]; // line length 
int cnt = 0, c; 
while ((c = read()) != -1) 
{ 
if (c == '\n') 
break; 
buf[cnt++] = (byte) c; 
} 
return new String(buf, 0, cnt); 
} 

public int nextInt() throws IOException 
{ 
int ret = 0; 
byte c = read(); 
while (c <= ' ') 
c = read(); 
boolean neg = (c == '-'); 
if (neg) 
c = read(); 
do
{ 
ret = ret * 10 + c - '0'; 
}  while ((c = read()) >= '0' && c <= '9'); 

if (neg) 
return -ret; 
return ret; 
} 

public long nextLong() throws IOException 
{ 
long ret = 0; 
byte c = read(); 
while (c <= ' ') 
c = read(); 
boolean neg = (c == '-'); 
if (neg) 
c = read(); 
do { 
ret = ret * 10 + c - '0'; 
} 
while ((c = read()) >= '0' && c <= '9'); 
if (neg) 
return -ret; 
return ret; 
} 

public double nextDouble() throws IOException 
{ 
double ret = 0, div = 1; 
byte c = read(); 
while (c <= ' ') 
c = read(); 
boolean neg = (c == '-'); 
if (neg) 
c = read(); 

do { 
ret = ret * 10 + c - '0'; 
} 
while ((c = read()) >= '0' && c <= '9'); 

if (c == '.') 
{ 
while ((c = read()) >= '0' && c <= '9') 
{ 
ret += (c - '0') / (div *= 10); 
} 
} 

if (neg) 
return -ret; 
return ret; 
} 

private void fillBuffer() throws IOException 
{ 
bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE); 
if (bytesRead == -1) 
buffer[0] = -1; 
} 

private byte read() throws IOException 
{ 
if (bufferPointer == bytesRead) 
fillBuffer(); 
return buffer[bufferPointer++]; 
} 

public void close() throws IOException 
{ 
if (din == null) 
return; 
din.close(); 
} 
} 
 */