There are n integers b1, b2, ..., bn written in a row. For all i from 1 to n, values ai are defined by the crows performing the following procedure:

  * The crow sets ai initially 0. 
  * The crow then adds bi to ai, subtracts bi + 1, adds the bi + 2 number, and so on until the n'th number. Thus, ai = bi - bi + 1 + bi + 2 - bi + 3.... 



Memory gives you the values a1, a2, ..., an, and he now wants you to find the initial numbers b1, b2, ..., bn written in the row? Can you do it?

Input

The first line of the input contains a single integer n (2 ≤ n ≤ 100 000) — the number of integers written in the row.

The next line contains n, the i'th of which is ai ( - 109 ≤ ai ≤ 109) — the value of the i'th number.

Output

Print n integers corresponding to the sequence b1, b2, ..., bn. It's guaranteed that the answer is unique and fits in 32-bit integer type.

Examples

Input

5
6 -4 8 -2 3


Output

2 4 6 1 3 


Input

5
3 -2 -1 5 6


Output

1 -3 4 11 6 

Note

In the first sample test, the crows report the numbers 6, - 4, 8, - 2, and 3 when he starts at indices 1, 2, 3, 4 and 5 respectively. It is easy to check that the sequence 2 4 6 1 3 satisfies the reports. For example, 6 = 2 - 4 + 6 - 1 + 3, and  - 4 = 4 - 6 + 1 - 3.

In the second sample test, the sequence 1,  - 3, 4, 11, 6 satisfies the reports. For example, 5 = 11 - 6 and 6 = 6.
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.Collection;
import java.util.List;
import java.util.Scanner;
import java.util.function.Function;
import java.util.stream.Collectors;
import java.util.stream.IntStream;
public class _p000712A {
    static public void main(final String[] args) throws IOException {
        p000712A._main(args);
    }
//begin p000712A.java
static private class p000712A extends Solver{public p000712A(){nameIn="p000712A.in"
;singleTest=true;}int n;int[]a;@Override protected void solve(){pw.println(IntStream
.range(0,n).map(i->i<n-1?a[i]+a[i+1]:a[i]).mapToObj(Integer::toString).collect(Collectors
.joining(" ")));}@Override public void readInput()throws IOException{n=sc.nextInt
();if(sc.hasNextLine()){sc.nextLine();}a=Arrays.stream(sc.nextLine().trim().split
("\\s+")).mapToInt(Integer::valueOf).toArray();}static public void _main(String[
]args)throws IOException{new p000712A().run();}}
//end p000712A.java
//begin net/leksi/contest/Solver.java
static private abstract class Solver{protected String nameIn=null;protected String
nameOut=null;protected boolean singleTest=false;protected boolean preprocessDebug
=false;protected boolean doNotPreprocess=false;protected Scanner sc=null;protected
PrintWriter pw=null;private void process()throws IOException{if(!singleTest){int
t=lineToIntArray()[0];while(t-->0){readInput();solve();}}else{readInput();solve(
);}}abstract protected void readInput()throws IOException;abstract protected void
solve()throws IOException;protected int[]lineToIntArray()throws IOException{return
Arrays.stream(sc.nextLine().trim().split("\\s+")).mapToInt(Integer::valueOf).toArray
();}protected long[]lineToLongArray()throws IOException{return Arrays.stream(sc.nextLine
().trim().split("\\s+")).mapToLong(Long::valueOf).toArray();}protected String joinToString
(final int[]a){return Arrays.stream(a).mapToObj(Integer::toString).collect(Collectors
.joining(" "));}protected String joinToString(final long[]a){return Arrays.stream
(a).mapToObj(Long::toString).collect(Collectors.joining(" "));}protected<T>String
joinToString(final T[]a){return Arrays.stream(a).map(v->v.toString()).collect(Collectors
.joining(" "));}protected<T>String joinToString(final T[]a,final Function<T,String>
toString){return Arrays.stream(a).map(v->v.toString()).collect(Collectors.joining
(" "));}protected<T>String joinToString(final Collection<T>a){return a.stream().map
(v->v.toString()).collect(Collectors.joining(" "));}protected<T>String joinToString
(final Collection<T>a,final Function<T,String>toString){return a.stream().map(v->
toString.apply(v)).collect(Collectors.joining(" "));}protected List<Long>intArrayToLongList
(final int[]a){return Arrays.stream(a).mapToObj(Long::valueOf).collect(Collectors
.toList());}protected List<Integer>toList(final int[]a){return Arrays.stream(a).mapToObj
(Integer::valueOf).collect(Collectors.toList());}protected List<Long>toList(final
long[]a){return Arrays.stream(a).mapToObj(Long::valueOf).collect(Collectors.toList
());}protected void run()throws IOException{boolean done=false;if(nameIn !=null)
{try{try(FileInputStream fis=new FileInputStream(nameIn);PrintWriter pw0=select_output
();){done=true;sc=new Scanner(fis);pw=pw0;process();}}catch(IOException ex){}}if
(!done){try(PrintWriter pw0=select_output();){sc=new Scanner(System.in);pw=pw0;process
();}}}private PrintWriter select_output()throws FileNotFoundException{if(nameOut
!=null){return new PrintWriter(nameOut);}return new PrintWriter(System.out);}}
//end net/leksi/contest/Solver.java
}
