Suppose I have a variable NN, and I am applying for loop 40 times….each loop may or may not change the variable NN….I want to know what is the last loop where the variable NN changes….for example:if the last change of NN occurs at 35th loop and no changes thereafter then, how should I know that it last changes at 35th loop by using the code?… can anyone help
MATLAB: How to keep track of last change in a variable inside the loop
forfor looploopMATLABvariable
Best Answer