Array row is not added in for loop
Mostra commenti meno recenti
I'm trying to add a new row whenever L*W*H = 50, but when I run it the array dimensiones does not change. What's going on...?
syms L W H;
dimensiones = [0, 0, 0];
for W = 1:100
L = W*3;
for H = 1:100
if L*W*H==50
dimensiones = [dimensiones; L, W, H];
end
end
end
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Mathematics in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!