
29.03.2008, 15:49
|
![Аватар для [MASTER]](image.php?u=3472&dateline=1206865359) |
Прохожий
|
|
Регистрация: 29.03.2008
Сообщения: 1
Репутация: 10
|
|
Код:
procedure StringCheck;
var
f:textfile;
i:integer;
s:string;
b:boolean;
st:array of string;
begin
AssignFile(f,'1.txt');
Reset(f);
b:=true;
while not(eof(f)) do begin
readln(f,s);
if s='Копия' then b:=not(b);
If b then begin
If not(s='Копия') then begin
SetLength(st,(Length(st)+1));
st[length(st)-1]:=s;
end;
end;
end;
Rewrite(f);
for i:=0 to Length(st)-1 do
writeln(f,st[i]);
CloseFile(f);
end;
Admin: Пользуемся тегами!
|