Trying to repeat this for loop
Info
Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.
Ältere Kommentare anzeigen
wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwweeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
1 Kommentar
Azzi Abdelmalek
am 7 Mai 2013
Why did you delete the question?
Antworten (1)
Azzi Abdelmalek
am 3 Mai 2013
Bearbeitet: Azzi Abdelmalek
am 3 Mai 2013
put the loop inside another loop. Can give more details how do you want to repeat this loop?
Edit
d=diff(p(1:100))
result=d==0
out=sum(result)
5 Kommentare
tunny
am 3 Mai 2013
Azzi Abdelmalek
am 3 Mai 2013
Bearbeitet: Azzi Abdelmalek
am 3 Mai 2013
you can use diff function
d=diff(p(1:100))
result=d==0
out=sum(result)
tunny
am 3 Mai 2013
Azzi Abdelmalek
am 3 Mai 2013
Bearbeitet: Azzi Abdelmalek
am 3 Mai 2013
Yes
p=[1 4 10 18]
diff(p)=[4-1 10-4 18-10]
tunny
am 3 Mai 2013
Diese Frage ist geschlossen.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!