MCQ Bank
What is the primary role of the control process in a loop structure?
- A) To reduce the flexibility of the algorithm.
- B) To avoid stepwise refinement.
- C) To guide the repetition of the loop.
- D) To execute the body of the loop.
Reason behind the Welsch NHS IT Failure was
- A) Weather conditions
- B) Software Technical issue
- C) Software Security issues
- D) Employees training
In the algorithm of Sequential search, what indicates a successful search from the given cases?
- A) Reaching the end of the list
- B) List is empty
- C) Equality of TargetValue and TestEntry
- D) Target value is greater than TestEntry
An alternative to translators
- A) Interpreter
- B) Mnemonics
- C) Compiler
- D) Assembler
Which of the following data type will be used for a variable having string of symbols and alphabets.
- A) Character
- B) Boolean
- C) Float
- D) Integer
Which of the following language is related to Object Oriented Paradigm.
- A) Python
- B) Smalltalk
- C) LISP
- D) Prolog
In the Ada programming language, what is the equivalent term for an "activation" in the context of concurrent processing?
- A) Function
- B) Process
- C) Task
- D) Operation
The set of tasks that ensures the software is correctly implements a specific function is known as
- A) Modularity
- B) Requirement gathering
- C) Validation
- D) Verification
In the pseudocode, what is the initial value of the variable max? def FindMax(): max = first number in the list Current = second number in the list While (elements in the list exist) If (max<current) max=current Current = next value in the list
- A) The maximum value representable in the programming language
- B) The first element in the list
- C) The second element in the list
- D) The last element in the list
A paradigm works on object called
- A) Functional paradigm
- B) Imperative paradigm
- C) Object oriented paradigm
- D) Declarative paradigm
In what case the statement "Give Scholarship" will NOT be executed in the following code? if (CGPA>=3.0) cout<<”Give Scholarship”; else cout<<”Sorry you do not qualify for the scholarship”;
- A) For any CGPA value above three
- B) Both statements will be executed in any case
- C) For CGPA value 2.9 or below
- D) CGPA is equal to three
The language understood by a computer without translation is known as:
- A) Machine Language
- B) Assembly language
- C) Command Language
- D) High Level Language
Someone can conclude that specifications of a software are met or not by:
- A) Validation
- B) Modularity
- C) Verification
- D) Requirement gathering
What is the role of the loop counter "i" in the given pseudo-code? f = 1 i=1 While (i<=n): f=f*i i=i+1
- A) To control the number of iterations in the loop
- B) To reset the loop condition
- C) To compare with the value of "n"
- D) To determine the initial value of "f"
What will be the value of "n" after the first iteration of the while loop in the given pseudo-code? f = 1 i=1; While (i<=n): f=f*i; i=i+1;
- A) n
- B) Cannot be determined
- C) 2
- D) 1
What is the purpose of the while loop in the pseudocode routine of the sequential search algorithm? Select the first entry in List to be TestEntry. while (TargetValue > TestEntry and there remain entries to be considered): Select the next entry in List as TestEntry. if (TargetValue == TestEntry): Declare search a success. else: Declare search a failure.
- A) To terminate the search
- B) To sort the list
- C) To iterate through the list entries
- D) To compare TestEntry with TargetValue
In the declarative paradigm, what does a programmer focus on when presented with a problem?
- A) Developing a sequence of commands
- B) Developing a precise statement of the problem
- C) Describing detailed algorithms
- D) Finding a general-purpose algorithm
In searching, If the target value is not in the original list, our approach to searching the list will proceed by dividing the list into
- A) Equal parts
- B) Not divide
- C) Smaller parts
- D) Greater parts
In what case both the print statements will be executed in the following code? if (marks>60) Print(You have passed the examination) Else Print(You have failed the examination)
- A) Marks are less than 60
- B) Marks are greater than 60
- C) Marks are less than or equal to 60
- D) Both cannot be executed at a time
In C++, symbolic representation for 'Equal to' relational operator is ________.
- A) ==
- B) =
- C) !=
- D) &