Multiple Choice Questions on Data Structure and Algorithm Design

Q. 1 The amount of time required to run to completion of any program is known as
a. Space complexity
b. Time complexity
c. Worst case complexity
d. Best case complexity

Q. 2 What is the minimum number of steps that can be executed for the given parameters in  a program?
a. Average case
b. Time complexity
c. Worst case
d. Best case

Q. 3 What is the maximum number of steps that can be executed for the given parameters in a program?
a. Average case
b. Time complexity
c. Worst case
d. Best case

Q. 4 ...............................is the average number of steps that can executed for the given parameters.
a. Average case
b. Time complexity
c. Worst case
d. Best case

Q. 5 Testing of a program consists of 2 phases which are ...............and .................... .
a. Average case & Worst case
b. Time complexity & Space complexity
c. Validation and checking errors
d.Debugging and profiling

Q. 6 Worst case time complexity of binary search is equal to
a. O(n)
b. O(logn)
c. O(nlogn)
d. O(logn)

Q. 7 Best case time complexity of binary search is equal to
a. O(n)
b. O(logn)
c. O(nlogn)
d. O(logn)

Q. 8 Average case time complexity of binary search is equal to
a. O(n)
b. O(logn)
c. O(nlogn)
d. O(logn)
Ans: O(logn)

Q. 9 Merge sort invented by
a. CARHOARE
b. JOHN VON NEUMANN
c. HAMILTON
d. STRASSEN

Q. 10 Quick sort invented by
a. CARHOARE
b. JOHN VON NEUMANN
c. HAMILTON
d. STRASSEN
Ans : CARHOARE

Q. 11 Worst case time complexity of Quick sort is equal to
a. O(n^2log7)
b. O(n^2)
c. O(nlogn)
d. O(logn)

Q. 12 Best case time complexity of Quick sort is equal to
a. O(n^2logn)
b. O(logn)
c. O(nlogn)
d. O(logn2)

Q. 13 Average case time complexity of Quick sort is equal to
a. O (nlogn)
b. O(logn)
c. O(nlogn)
d. O(logn)

Q. 14 Which design strategy stops the execution when it find the solution otherwise starts the problem from top
a. Back tracking
b. Branch and Bound
c. Divide and conquer
d. Dynamic programming
Ans: Back Tracking

Q. 15 Graphical representation of algorithm is known as
a. Pseudo-code
b. Flow Chart
c. Graph Coloring
d. Dynamic programming

Q. 16 In pseudo-code conventions input express is known as
a. input
b. Write
d. Return

Q. 17 In pseudo-code conventions output express is known as
a. input
b. Write
d. Return

Q. 18 Performance based criteria of algorithm , which has to do with its computing time is
a. Time Complexity
b. Space Complexity
c. Input
d. Finiteness

Q. 19 Performance based criteria of algorithm , which has to do with its storage requirements is
a. Time Complexity
b. Space Complexity
c. Input
d. Finiteness

Q. 20 O(1) means computing time is
a. Constant
b. Linear
d. Cubic

Q. 21 O(n) means computing time is
a. Constant
b. Linear
d. Cubic

Q. 22 O(n^2) means computing time is
a. Constant
b. Linear
d. Cubic

Q. 23 O(n^3) means computing time is
a. Exponential
b. Linear
d. Cubic

Q. 24 O(2^n) means computing time is
a. Constant
b. Linear
d. Exponential

Q. 25 Application of quick-sort is
a. Graphic card
b. Tape sorting
c. Data Processing
d. Card Sorting

Q. 26 Application of merge-sort is
a. Graphic card
b. Networking
c. Card Sorting
d. Data Processing

Q. 27 Which method will choosing when sub problems share sub problems
a. Divideand conquer
b. Dynamic programming
c. Greedy method
d. Back tracking

Q. 28 The sorting methods , which works very well for small file is known as
a. Count sort
b. Merge sort
c. Selection sort
d. Quick sort

Q. 29 Merge sort is known as
a. External sorting
b. Internal sorting
c. Insertion sorting
d. Exponential sorting

Q. 30 Step-by-step procedure for calculations is known as
a. Program
b. Greedy Method
c. Algorithm
d. Problem

Q. 31 Advantage of finding maximum and minimum using divide and conquer method instead of using conditional operators is known as
a. Reduce Space complexity
b. Reduce Time complexity
c. Get accurate value
d. Simple calculations

Q. 32 The general criteria of algorithm; at least one quantity is produced is
a. Output
b. Finiteness
c. Effectiveness
d. Input

Thanks
Mukesh Rajput

Mukesh Rajput

I am a Computer Engineer, a small amount of the programming tips as it’s my hobby, I love to travel and meet people so little about travel, a fashion lover and love to eat food, I am investing a good time to keep the body fit so little about fitness also..