program seven; function UpCaseRus(C:char):Char; var s1,s2:string; R1:char; begin s1:='йцукенгшщзхъфывапролджэячсмитьбю'; s2:='ЙЦУКЕНГШЩЗХЪФЫВАПРОЛДЖЭЯЧСМИТЬБЮ'; if Pos(''+C,s1)>0 then R1:=s2[Pos(''+C,s1)] else R1:=C; UpCaseRus:=R1 end; const Razd=[' ','.','!','?',',']; const Zv =['Б','В','Г','Д','Ж','З','Л','М','Н','Р']; var a,b,a1,m:set of char; c:char; s,fa,slovo:string; f:text; i,j:integer; begin a:=[]; b:=[]; j:=1; a:=Zv;a1:=[]; readln(s);{} for i:=1 to length(s) do if s[i] in Razd then begin if not((i>1) and (s[i-1] in Razd)) then begin if (odd(j)) then begin a:=a*a1; a1:=[] end; j:=j+1 end end else begin c:=UpCaseRus(s[i]); if (c in Zv) then if (odd(j)) then a1:=a1+[c] else b:=b+[c] end; if (a1<>[]) and (odd(J)) then a:=a*a1; m:=a-b; write('В каждом нечетном:'); for c:='Б' to 'Р' do if c in a then write(c); writeln; write('В четных:'); for c:='Б' to 'Р' do if c in b then write(c); writeln; write('По условию:'); for c:='Б' to 'Р' do if c in m then write(c); if m=[] then writeln('Нет'); end.