Category Archives: MatLab Multiple Choice Questions

If I want to save a formatted string to memory, but don’t want to print it out, which command should I use? | MatLab Mcqs

a) fprintf b) sprintf c) disp d) echo Ans: b

Posted in MatLab Multiple Choice Questions | Leave a comment

What is the value of ans that is printed when the following code is run: isnumeric(32) | MatLab Mcqs

a) 1 b) 0 c) 32 d) yes e) true Ans: a

Posted in MatLab Multiple Choice Questions | Leave a comment

If vector = [1 2 3 4; 11 24 92 100; 345 65 90 1]. What will the value of a be equal to if this code is entered into MATLAB >>[a b] = size (vector)? | MatLab Mcqs

a) 1 2 3 4 b) 12 c) 1 d) 4 e) 3 Ans: e

Posted in MatLab Multiple Choice Questions | Leave a comment

Which of the following is used to see if two elements are equal in MATLAB? | MatLab Mcqs

a) != b) == c) isequal d) = e) none of the above Ans: b

Posted in MatLab Multiple Choice Questions | Leave a comment

Which of these is the way to access the first element in a vector named v (assuming there is at least one element in the vector)? | MatLab Mcqs

a) v(0) b) v(1) c) v d) v(: , 0) e) none of the above Ans: b

Posted in MatLab Multiple Choice Questions | Leave a comment

Which of the following will correctly define x, y, and z as symbols? | MatLab Mcqs

a) sym (x, y, z) b) syms x y z c) syms x, y, z d) sym x, y, z e) none of the above Ans: b

Posted in MatLab Multiple Choice Questions | Leave a comment

In Matlab, this keyword immediately moves to the next iteration of the loop: | MatLab Mcqs

a) update b) goto c) continue d) break e) none of the above Ans: c

Posted in MatLab Multiple Choice Questions | Leave a comment

To print a newline in a fprintf statement, you must use the following escape character: | MatLab Mcqs

a) \t b) \nl c) \nxt d) \n e) none of the above Ans: d

Posted in MatLab Multiple Choice Questions | Leave a comment

To better manage memory and prevent unnecessary memory allocations, Matlab uses: | MatLab Mcqs

a) vectors b) scalars c) matrix math d) delayed copy e) licenses Ans: d

Posted in MatLab Multiple Choice Questions | Leave a comment

Which is these is not an aspect of a for/while loop: | MatLab Mcqs

a) update b) initialization c) runner d) condition e) all are aspects of loops Ans: c

Posted in MatLab Multiple Choice Questions | Leave a comment