How can i use various Loops in matlab

I am very new to using MATLAB and i have been trying to work with loops, for making a freeware automatic mouse mover can someone educate me regarding the number of loops that matlab provides and the variation in which i can use them.

Answers (1)

The basic loop types in MATLAB are the while loop and the for loop.
x=100
while x>10
x=x-1
end
and:
for n=1:100
x=x+1
end

This question is closed.

Tags

Asked:

on 7 Feb 2019

Closed:

on 20 Aug 2021

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!