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.