Q:

Create a vector of five random integers, each in the inclusive range from -10 to 10. Perform each of the following:

0
  1. subtract 3 from each element
  2. count how many are positive
  3.  get the cumulative minimum 

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

Answers:

1/ >> vec-3

2/  >> sum(vec > 0)

3/ >> vec = randi([-10, 10], 1,5)

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now