procedure TForm1.Button2Click(Sender: TObject);var S:String; A1,A2,A3,I:Integer;begin S:=Edit1.Text; A1:=0; A2:=0; A3:=0; for i:=1 to Length(S) DO if (S in ['0'..'9']) Then Inc(A1) ELSE IF S In ['A'..'Z','a'..'z'] Then Inc(A2) ELSE IF S IN [' '] Then Inc(A3);end;smlabc给你回答了问题后,你不结贴,然后把原先的问题改为现在的问题了?