MATLAB: What the difference between run and debug???
code
when I am used debug get same effect of run????????????
Best Answer
What do you mean by debug? There is no debug button. There is a run button and it's the green triangle. Debugging is the process of stepping through your code and examining variables and output to see how the code operates, and if there's anything wrong with it. You need to run your code to debug it. But, of course, you can just run your code without debugging it - there's no requirement to set breakpoints, step a line at a time through your code, etc. You can just "let 'er rip."
There's no way to say "stop whenever a new function gets called" in debug mode without setting breakpoints.
But if you're debugging your code you can "Step In" to the function that gets called on a particular line. You can also "Run to Cursor" to move your cursor to a particular line and automatically execute up to that point. See the "Step Through File" section on this documentation page for more information.
Best Answer