Azzera filtri
Azzera filtri

How to skip the following for loop

1 visualizzazione (ultimi 30 giorni)
A.K
A.K il 11 Ago 2016
Modificato: Azzi Abdelmalek il 11 Ago 2016
When the condition of an if statement is met, it will do an assignment, and then it should skip the following for loop. If the condition of the if statement is not met, the program should then move into the for loop.
if(condition)
A=B;
Skip for loop.
end
for i=1:L
lines of code;
end

Risposte (1)

Azzi Abdelmalek
Azzi Abdelmalek il 11 Ago 2016
Modificato: Azzi Abdelmalek il 11 Ago 2016
if(condition)
A=B;
else
for i=1:L
lines of code;
end
end

Categorie

Scopri di più su Loops and Conditional Statements in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by