凑个热闹,再贴一个
procedure GetStr(const S:string;var str1,str2:string);
var
p:^char;
i:integer;
temp:string;
begin
temp:='';
for i:=1 to length(S) do
begin
p:=@S[i];
case p^ of
'(':begin
str1:=temp;
temp:='';
end;
')':str2:=temp;
else
temp:=temp+P^;
end;
end;
end;
var i:integer; date:sting;
function findNUM(s:string):string;
begin
begin
date:=' ';
for i:=1 to length(s) do
begin if (s[i]>='0')and(s[i]<='9')
then
date:=date+s[i];//从字符串中取数字,
end;
end;
end;