var i:integer; var f,g:text; var s:string; begin assign (f, 'input.txt'); assign (g, 'output.txt'); reset(f); rewrite(g); while not (eof(f)) do readln(f, s); while(pos('короче', s)>0) do begin i:=pos('короче', s); delete(s, i, 7); insert('в общем',s, i); end; writeln(g,s); close(f); close(g); readln; end.
var i:integer;
var f,g:text;
var s:string;
begin
assign (f, 'input.txt');
assign (g, 'output.txt');
reset(f);
rewrite(g);
while not (eof(f)) do readln(f, s);
while(pos('короче', s)>0) do begin
i:=pos('короче', s);
delete(s, i, 7);
insert('в общем',s, i);
end;
writeln(g,s);
close(f);
close(g);
readln;
end.