{ NOTE: it is recommended to use this even if you don't understand the following code. }

{ constraints }
const
    MAXN = 1000;

{ input data }
var
    N,M,i,j : longint;
    P       : array[0..MAXN-1,0..MAXN-1] of longint;
    R       : array[0..MAXN-1] of double;

begin
{
    uncomment the following lines if you want to read/write from files
    assign(input,  'input.txt');  reset(input);
    assign(output, 'output.txt'); rewrite(output);
}

    readln(N, M);
    for j:=0 to M-1 do begin
        for i:=0 to N-1 do
            read(P[i,j]);
        readln();
    end;
    readln();

    R[0] := 42; { insert your code here }

    for i:=0 to N-1 do
        write(trunc(R[i]), ' '); { print result }
    writeln();
end.
