For To Do Delphi 7 ( I need help fast , please)
procedure TForm1.executarClick(Sender: TObject);
var
N,I,T:Integer;
begin
N:=StrToInt(num.Text);
tabuada.Items.Clear;
For I:= 1 to 11 do
begin
T:=N*I;
tabuada.items.add(IntToStr(T));
I:=I+1;
end;
end.
var
N,I,T:Integer;
begin
N:=StrToInt(num.Text);
tabuada.Items.Clear;
For I:= 1 to 11 do
begin
T:=N*I;
tabuada.items.add(IntToStr(T));
I:=I+1;
end;
end.
Samuel
Curtidas 4
Mais Respostas
Raimundo Pereira
28/06/2016
var
N,I,T:Integer;
begin
N:=StrToInt(num.Text); //= Valor informado no edit
tabuada.Items.Clear;//limpou a tabuada
For I:= 1 to 11 do // Sua var iniciar é 1 e o limite é 11
begin
T:=N*I;
tabuada.items.add(num.Text+' X '+IntToStr(i)+'='+(IntToStr(T)));
//I:=I+1;////Enquanto não chegar ao limite que é 11 ele irá passar para o próximo algarismo por si mesmo, então basta comentar
end;
end;
//Resulta do teste que eu fiz
1 X 1=1
1 X 2=2
1 X 3=3
1 X 4=4
1 X 5=5
1 X 6=6
1 X 7=7
1 X 8=8
1 X 9=9
1 X 10=10
1 X 11=11
N,I,T:Integer;
begin
N:=StrToInt(num.Text); //= Valor informado no edit
tabuada.Items.Clear;//limpou a tabuada
For I:= 1 to 11 do // Sua var iniciar é 1 e o limite é 11
begin
T:=N*I;
tabuada.items.add(num.Text+' X '+IntToStr(i)+'='+(IntToStr(T)));
//I:=I+1;////Enquanto não chegar ao limite que é 11 ele irá passar para o próximo algarismo por si mesmo, então basta comentar
end;
end;
//Resulta do teste que eu fiz
1 X 1=1
1 X 2=2
1 X 3=3
1 X 4=4
1 X 5=5
1 X 6=6
1 X 7=7
1 X 8=8
1 X 9=9
1 X 10=10
1 X 11=11
GOSTEI 0