250+ TOP MCQs on Toolbox Distribution – 2 and Answers

Tough MATLAB Questions and Answers on “Toolbox Distribution – 2”.

1. What does the function matlab.addons.toolbox.installedToolboxes return?
a) A structure
b) A table
c) A structure of arrays
d) An array of structure
Answer: c
Clarification: The above command returns a structure of arrays which are the Name, Version and Guide of the toolboxes installed in the system. It can be converted to array form and then viewed properly.

2. What is the output of the following code?

ver Simulink

a) Shows the version of MATLAB
b) Shows the version of MATLAB and the Simulink Toolbox
c) Shows the version of the Simulink Toolbox
d) Shows the contents of Simulink Toolbox
Answer: b
Clarification: The ver function along with the name of a toolbox returns the version of the installed MATLAB version and the version of the toolbox.

3. What is the output of the above code?

ver Simulink Toolbox

a) Error
b) Shows the version of MATLAB
c) Shows the version of MATLAB and the Simulink Toolbox
d) Shows the version of the Simulink Toolbox
Answer: a
Clarification: The name of the toolbox is Simulink only. Hence, Toolbox written in the above code is an excess input and the output results in an error. The output would’ve been shows the version of MATLAB and the simulink toolbox if only Simulink was written.

4. A .mltbx toolbox is written in Java.
a) True
b) False
Answer: b
Clarification: A .mltbx toolbox is a toolbox which is written in the MATLAB environment only. Hence, the above statement is false.

  250+ TOP MCQs on Errors in Input – 1 and Answers

5. A toolbox is same as a function.
a) True
b) False
Answer: b
Clarification: A toolbox has a multitude of function. It itself is not a function. It can be thought of as a header file.

6. What is the output of the following code?

matlab.addons.toolbox.uninstallToolbox[]

a) Error
b) Uninstalls the toolbox given in the input
c) Uninstalls all the toolboxes
d) Uninstalls the function given in the input
Answer: a
Clarification: The input to the above command is to be given within parentheses. If the input is given in the syntax shown above, it’ll result in an error.

7. What is the output of the following code?

matlab.addons.Toolbox.uninstalltoolbox()

a) Uninstalls the toolbox given in the input
b) Error
c) Uninstalls all the toolboxes in the system
d) Uninstalls the function given in the input
Answer: b
Clarification: There has been an error while spelling the command. It should be matlab.addons.toolbox.uninstallToolbox[], but it’s not so in the above code. Hence, this leads to an error.

8. What are the contents of the toolbox shown by the matlab.addons.toolbox.installedToolboxes command?
a) Name, Guid
b) Name, Version, Guid
c) Name, package, Guid
d) Name, package,
Answer: b
Clarification: The given command returns the properties of the installed toolbox, given by option name, version, guid. The guid is the toolbox identifier.

tough questions and answers on ,

Scroll to Top