for-next loop parameter gets printed out
Show older comments
Curious behavior. I have a matlab code with lots of for-next loops. One in particular that starts with
for I = J:LL
for some reason resulted in the LL value being printed out unexpectedly. None of my other for-next loops
did this. When I changed the statement to read
for I = J:LL;
i.e., I added a semicolorn to the end, LL was NOT printed out. This is worrisome because I'm not sure something
else has gone wrong. How does one track down what causes this behavior?
2 Comments
dpb
on 20 Aug 2022
Can you post a code snippet that exhibits the suspect behavior?
I've never seen it happen but I've not upgraded to a more recent release than R2020b yet, either, if somehow something got broken in an update.
Ken Bannister
on 21 Aug 2022
Moved: Voss
on 21 Aug 2022
Accepted Answer
More Answers (0)
Categories
Find more on Startup and Shutdown in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!