MATLAB MCQ: MATLAB  Multiple Choice Questions and Answers

MATLAB MCQ with answers and explanations for placement tests and job interviews. These solved MATLAB MCQs are useful for the campus placement for all freshers including Engineering Students, MCA students, Computer and IT Engineers, etc.

Our MATLAB MCQ (MATLAB Multiple Choice Questions ) focuses on various parts of the MATLAB multi-paradigm programming language and its concept. It will be useful for anyone learning MATLAB Basics, Essentials, and/or Fundamentals. We will regularly update the quiz and most interesting thing is that questions come in a random sequence. So every time you will feel new questions.

There are several MATLAB courses that you may have come across during your search for learning the MATLAB multi-paradigm programming language. Our team of experts has carefully analyzed some MATLAB courses for you. You can check the courses, Trial of some courses is free.

 

Guideline of MATLAB MCQ:

This MATLAB MCQ is intended for checking your MATLAB knowledge. It takes 50 minutes to pass the MATLAB MCQ. If you don’t finish the MATLAB MCQ within the mentioned time, all the unanswered questions will count as wrong. You can miss the questions by clicking the “Next” button and return to the previous questions by the “Previous” button. Every unanswered question will count as wrong. MCQ on MATLAB has features of randomization which feel you a new question set at every attempt.

In this MATLAB MCQ, we have also implemented a feature that not allowed the user to see the next question or finish the MATLAB quiz without attempting the current MATLAB MCQ.

0 votes, 0 avg

You have 50 minutes to take the MATLAB MCQs

Your time has been Over.


MATLAB MCQ

MATLAB MCQ: MATLAB  Multiple Choice Questions and Answers

1 / 33

Which statement returns 1 (true)?

a = 'stand'
b = "stand"

 

2 / 33

What built-in definition does i have?

3 / 33

If you run this piece of code, you will get an error. Why?

a = [0 1 2 3; 4 5 6 7];
a = a^2;

 

4 / 33

What is the value of c?

a = ones(1,3);
b = 1:3;
c = conv(a,b)

 

5 / 33

Which statement turns menu into the variable menu_string below?

menu = {'hot dog' 'corn dog' 'regular burger' 'cheeseburger' 'veggie burger'}
menu_string =
    'hot dog
     corn dog
     regular burger
     cheeseburger
     veggie burger'

 

 

6 / 33

Where in the UI can you see what variables have been created, their values, and their class?

7 / 33

Which does E contain?

C = {'dog' 'cat' 'mouse'}
D = {'cow' 'piranha' 'mouse'}
E = setdiff(C,D)

 

8 / 33

You have plotted values of cosine from -10 to 10 and want to change the x-axis tick marks to every pi, from -3pi to 3pi. Which statement will do that?

9 / 33

You have loaded a dataset of people's heights into a 100 x 1 array called height. Which statement will return a 100 x 1 array, sim_height, with values from a normal distribution with the same mean and variance as your height data?

10 / 33

Based on the code below, c is the \_ of a.

a = rand(1, 11);
b = sort(a);
c = b(1, ceil(end/2));

 

11 / 33

What kind of files are stored with the .mat extension?

12 / 33

Which statement returns the roots for the polynomial x^2 + 2x - 4?

13 / 33

my_func is a function as follows. What is the value of a at the end of the code beneath?

function a = my_func(a)
    a = a + 1;
end
------------------
a = 0;
for i = 1:3
    my_func(a);
end
a = my_func(a);

 

14 / 33

How do you access the value for the field name in structure S?

15 / 33

Which statement is equivalent to this for loop?

a = [1 2 3; 4 5 6];
b = zeros(size(a));
for i_row = 1:size(a, 1)
    for i_col = 1:size(a, 2)
        b(i_row, i_col) = a(i_row, i_col)^2;
    end
end

 

16 / 33

Which statement creates a logical array that is 1 if the element in passwords contains a digit and 0 if it does not?

passwords = {'abcd' '1234' 'qwerty' 'love1'};

 

17 / 33

For which of these arrays do mean, median, and mode return the same value?

18 / 33

What is the set of possible values that a may contain?

a      = randi(10, [1, 10]);
a(3)   = 11;
a(a>2) = 12;

 

19 / 33

Which function could you use for multiple linear regression?

20 / 33

Which statement is true about the sparse matrices?

21 / 33

Which statement returns a cell array of the strings containing 'burger' from menu?

menu = {'hot dog' 'corn dog' 'regular burger' 'cheeseburger' 'veggie burger'}

 

22 / 33

what is the . character NOT used for?

23 / 33

Which choice adds b to each row of a?

a = ones(4, 4);
b= [1 2 3 4];

 

24 / 33

What is true of a handle class object?

25 / 33

Which is NOT a function that adds text to a plot?

26 / 33

You are in the middle of a long MATLAB session where you have performed many analyses and made many plots. You run the following commands, yet a figure window doesn't pop up on the top of your screen with your plot. What might be the issue?

x = [-1:0.1:1];
y = X.^2;
plot(x, y)

 

27 / 33

Which function CANNOT be used to randomly sample data?

28 / 33

From what distribution does the rand() function return value?

29 / 33

Which statement using logical indices will result in an error?

a = 1:10;

 

30 / 33

Which choice is the proper syntax to append a new elements a to the end of 1x 2 dimensional cell array C?

31 / 33

Which statement could create this cell array?

c =
    {["hello world"]}    {1×1 cell}    {["goodbye"]}    {1×3 double}

 

32 / 33

What is %% used for?

33 / 33

What does the Profiler track?

Your score is

The average score is 0%

0%

Recommended Articles for you: