how to use output as input in same code

7 visualizaciones (últimos 30 días)
GAURAV DHADSE
GAURAV DHADSE el 17 de Sept. de 2019
Comentada: GAURAV DHADSE el 17 de Sept. de 2019
h = 2
for I = 1:15
E = 0
for el = 1:20
M = 1 +h
E = E + M
end
end
how can I use the new value of E for each iteration?
  5 comentarios
KALYAN ACHARJYA
KALYAN ACHARJYA el 17 de Sept. de 2019
Editada: KALYAN ACHARJYA el 17 de Sept. de 2019
h=2
E=0
for ...
for ...
....
E=E+M % Update E
end
end
Role of I loop ??
GAURAV DHADSE
GAURAV DHADSE el 17 de Sept. de 2019
Dear Walter sir, thanks for the answer, now my code is running properly. Thank you everyone

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Multicore Processor Targets en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by