writeln('+ Kolichestvo avtomobilei kazdoi marki ->4 +');
writeln('+ Vladelec samogo starogo avtomobila ->5 +');
writeln('+ Familii vladelcev i nomera avto dannoi marki ->6 +');
Writeln('+ +');
writeln('+ Konec ->0 +');
Writeln('+++++++++++++++++++++++++++++++++++++++++++++++++++++');
writeln;
end;
begin
for i := 1 to 200 do
ch[i] := false;
clrscr;
menu;
cont := true;
fzap := false;
while cont do
begin
write('Vvedite komandu: ');
readln(command);
case command of
'0': cont := false;
'1':
begin
Write('Vvedite kol-vo zapisei(1..200): ');
readln(n);
if (n > 0) and (n <= 200) then
fzap := true else fzap := false;
end;
'2':
begin
if fzap = true then
begin
for i := 1 to n do
change(i, avtovl, ch);
clrscr; menu;
end
else writeln('Ne vvedeno kol-vo zapisei');
end;
'3':
begin
if fzap = true then
begin
write('Vvedite nomer redaktiryemoi zapisi: ');
readln(i);
if i > n then writeln('Wrong input')
else
begin
change(i, avtovl, ch);
clrscr;
menu;
end;
end
else Writeln('Ne vvedeno obshee chislo zapisei');
end;
'4':
begin
if fzap = true then
begin
for i := 1 to n do
if ch[i] = false then
begin
dzap := false;
writeln('Vvedeni ne vse zapisi');
end
else dzap := true;
if dzap = true then
mark(avtovl);
end
else
Writeln('Ne vvedeno obshee chislo zapisei');
end;
'5':
begin
if fzap = true then
begin
for i := 1 to n do
if ch[i] = false then
begin
dzap := false;
writeln('Vvedeni ne vse zapisi');
end
else dzap := true;
if dzap = true then
mostold(avtovl);
end
else
Writeln('Ne vvedeno obshee chislo zapisei');
end;
'6':
begin
if fzap = true then
begin
for i := 1 to n do
if ch[i] = false then
begin
dzap := false;
writeln('Vvedeni ne vse zapisi');
end
else dzap := true;
if dzap = true then
oprmarki(avtovl);
end
else
Writeln('Ne vvedeno obshee chislo zapisei');
end;
end;
end;
end.