Create a variable myend which stores a random integer in the inclusive range from 5 to 9. Using the colon operator, create a vector that iterates from 1 to myend in steps of 3
belongs to book: MATLAB: A Practical Introduction to Programming and Problem Solving|Stormy Attaway|Fourth Edition| Chapter number:2| Question number:10.2
All Answers
total answers (1)
>> myend = randi([5, 9]) myend = 8 >> vec = 1:3:myend vec = 1 4 7
need an explanation for this answer? contact us directly to get an explanation for this answer