Can you determine the number of times a while() statement has run before it finally ends?

2 views (last 30 days)
I am creating a while function and need to determine the number of cycles it went through before finally coming to completion. Thanks for your help!

Accepted Answer

Sai kasyap
Sai kasyap on 17 Sep 2015
%num is number of times u execute loop
num =0;
while your condition
num = num+1;
end

More Answers (0)

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!