天 天空4567 Unregistered / Unconfirmed GUEST, unregistred user! 2006-04-04 #1 如何将字符串顺序给一个空数组?字符串是当前随意输入的。
B babibean Unregistered / Unconfirmed GUEST, unregistred user! 2006-04-04 #2 var a:array[0..9] of string; str:string; i:integer; begin str:='2385511113'; for i :=0 to length(a)-1 do begin a:=str[i+1]; if i>=length(str)-1 then break; end; end;
var a:array[0..9] of string; str:string; i:integer; begin str:='2385511113'; for i :=0 to length(a)-1 do begin a:=str[i+1]; if i>=length(str)-1 then break; end; end;
天 天空4567 Unregistered / Unconfirmed GUEST, unregistred user! 2006-04-04 #3 执行到 a:=str[i+1];这里时就系统出错。 怎么回事?
L liuchong Unregistered / Unconfirmed GUEST, unregistred user! 2006-04-04 #4 var MyAry:array of Char; S:String; I:LongWord; begin S:=Edit1.Text; SetLength(MyAry,Length(S)); for I:=0 to High(MyAry) do MyAry:=S[I+1]; end;
var MyAry:array of Char; S:String; I:LongWord; begin S:=Edit1.Text; SetLength(MyAry,Length(S)); for I:=0 to High(MyAry) do MyAry:=S[I+1]; end;
Q qcchan Unregistered / Unconfirmed GUEST, unregistred user! 2006-04-04 #5 hehe,刚才写错了 var a:array[0..9] of string; str:string; ppchar; begin str:='2385511113'; strpcopy(pp,str); a[0]:=pp; end;
hehe,刚才写错了 var a:array[0..9] of string; str:string; ppchar; begin str:='2385511113'; strpcopy(pp,str); a[0]:=pp; end;