uses crt;
const n=3;
type rec=record
nap1,nap2:string;
vr1,vr2:byte;
end;
var x:array[1..n] of rec;
i,a,b,k:byte;
begin
ClrScr;
for i:=1 to n do
with x[i] do
begin
Write(' Napravleniey:(Volgograd-Moskva): ');
Readln(nap1);
Write('-');
Readln(nap2);
Write(' Time(14-22): ');
Readln(vr1);
Write('-');
Readln(vr2);
end;
Writeln('Table: ');
Writeln('------------------------------------');
Writeln('|| N | Napravleniye | Time ||');
Writeln('------------------------------------');
for i:=1 to n do
Writeln('|| ',i,' |',x[i].nap1,'-',x[i].nap2,'|':15,
x[i].vr1,'-',x[i].vr2,'||':9);
Writeln('------------------------------------');
Writeln('Vvedite vremja(14-22): ');
Readln(a);
Write('-');
Readln(b);
k:=0;
for i:=1 to n do
if (x[i].vr1>=a) and (x[i].vr2<=b) then
inc(k);
Writeln('Kol: ',k);
Readln;
end.