Autor Beitrag
lord.paddington
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 76



BeitragVerfasst: Sa 23.07.05 20:19 
Hi!

Habe eine Schleife bspw.
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
for i := 1 to 20 do
begin
  if test[i] = 0 then
  begin
    ???
  end;
  test1[i] := test2[i];
end;


Was muss anstelle der Fragezeichen stehen, damit nicht die Schleife, aber wenigstens dieser eine Schleifendurchlauf beendet wird?

Ein 'break' bringt mich nicht weiter....

Moderiert von user profile iconChristian S.: Code- durch Delphi-Tags ersetzt.

_________________
pfutsch ist hin und hin ist pfutsch
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Sa 23.07.05 20:22 
Wenn ich das richtig verstehe, sollte continue; Dein Freund sein :-)

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".
Harry M.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 754

Win 2000, XP
D2005
BeitragVerfasst: Sa 23.07.05 21:35 
Wiseo bringt dichbreake nicht weiter.

//Edit: alles klar: Habe nochmal richtig gelsen! :oops:

_________________
Gruß Harry
Et spes me per dies sine te ducat et amor me ferat, si dolor spem tollit.
hallo
ontopic starontopic starontopic starontopic starhalf ontopic starofftopic starofftopic starofftopic star
Beiträge: 450

WIN XP, SuSE 9.3
D3 Prof, D6 Pers, 2005 Pers
BeitragVerfasst: So 24.07.05 15:55 
Also bisher hab ich sowas immer so gemacht:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
...
var cont:boolean;
...
for i := 1 to 20 do  
begin  
cont:=true;
if test[i] = 0 then  
begin  
cont:=false;  
end; 
if (cont=true)then
begin 
test1[i] := test2[i]; 
end; 
end;


Wenn ich jetzt alles richtig verstanden habe...

//sry: der browser will des irgendwie grad nicht einrücken...

_________________
Der beste je Programmierte Trojaner: Windows XP
Wäre es nicht adequat, den Usus heterogener Termini zu minimieren?


Zuletzt bearbeitet von hallo am So 24.07.05 15:59, insgesamt 1-mal bearbeitet
JayEff
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2971

Windows Vista Ultimate
D7 Enterprise
BeitragVerfasst: So 24.07.05 15:57 
Ähm.
1.: Benutze delphitags anstatt Code tags. [delphi][/delphi] Dann "rückt der Browser" das auch ein.
2.: Benutze doch continue; wie Christian schon gesagt hat?

_________________
>+++[>+++[>++++++++<-]<-]<++++[>++++[>>>+++++++<<<-]<-]<<++
[>++[>++[>>++++<<-]<-]<-]>>>>>++++++++++++++++++.+++++++.>++.-.<<.>>--.<+++++..<+.