uses crt;
const n=4;
type Tmatr=array[1..n,1..n] of integer;
procedure Vvod(var mt:Tmatr);
var i,j:byte;
begin
writeln('Vvedite ',n*n,' elementov matricy:');
for i:=1 to n do
for j:=1 to n do
read(mt[i,j]);
readln;
clrscr;
writeln('Matrica:');
for i:=1 to n do
begin
for j:=1 to n do
write(mt[i,j]:4);
writeln;
end;
end;
function Prz(mt:Tmatr):longint;
var i,j:byte;
pr:longint;
begin
pr:=1;
for i:=1 to n do
for j:=1 to n do
if j<=n-i+1 then pr:=pr*mt[i,j];
Prz:=pr;
end;
var a:Tmatr;
begin
clrscr;
Vvod(a);
write('Proizvedenie=',Prz(a));
readln
end.