var
 S: string;
 I: Integer;
 Found: Boolean;
begin
 S := 'Hello World';
 Found := False;
 I := Low (S);
 while not Found and (I <= High(S)) do begin
 if (S[I]) = 'o' then
 Found := True;
 Inc (I);
 end;

发表回复

后才能评论