Which of the following expressions generates the integer vector 1, 2, 3, 4, 5?
- Correct.
- Wrong. This command will return a length-one vector containing only 1.
- Correct.
- Correct.
- Correct.
What is the value of a * b
, given the following vectors?
\[ \begin{align*} a &= 5, 2, 1\\ b &= 1, 2, 3 \end{align*} \]
- Format you answer as
element1, element2, element3, ...
- Separate each element with a comma and a space.
- Incorrectly formatted answers won’t be recognized as correct
The a * b
implements element-wise multiplication, so the result is 5, 4, 3.