How can I stop the program? "Break" - Error
Show older comments
I am using a "Break" to stop the program but it is showing an error. How can I solve that and stop the program? Thanks

Accepted Answer
More Answers (1)
Birdman
on 26 Oct 2017
Break is used to stop for or while loops. Just throw an error by typing:
error('Break');
Categories
Find more on Loops and Conditional Statements 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!