Structures and Algorithms 5

COEP
Lets Crack Online Exam

Electronic Engineering MCQ Question Papers: ENTC, IT Interview Placement

Subject:  Structures and Algorithms 5

Part 5: List for questions and answers of Data Structures & Algorithms

 

Q1. The Worst case occur in linear search algorithm when

a) Item is somewhere in the middle of the array

b) Item is not in the array at all

c) Item is the last element in the array

d) Item is the last element in the array or is not there at all

 

Q2. The Average case occur in linear search algorithm

a) When Item is somewhere in the middle of the array

b) When Item is not in the array at all

c) When Item is the last element in the array

d) When Item is the last element in the array or is not there at all

 

Q3. The complexity of the average case of an algorithm is

a) Much more complicated to analyze than that of worst case

b) Much more simpler to analyze than that of worst case

c) Sometimes more complicated and some other times simpler than that of worst case

d) None or above

 

Q4. The complexity of linear search algorithm is

a) O(n)

b) O(log n)

c) O(n2)

d) O(n log n)

 

Q5. The complexity of Binary search algorithm is

a) O(n)

b) O(log )

c) O(n2)

d) O(n log n)

 

Q6. The complexity of Bubble sort algorithm is

a) O(n)

b) O(log n)

c) O(n2)

d) O(n log n) 

 

Q7. The complexity of merge sort algorithm is

a) O(n)

b) O(log n)

c) O(n2)

d) O(n log n)

 

Q8. The indirect change of the values of a variable in one module by another module is called

a) Internal change

b) Inter-module change

c) Side effect

d) Side-module update

 

Q9. Which of the following data structure is not linear data structure?

a) Arrays

b) Linked lists

c) Both of above

d) None of above

 

Q10. Which of the following data structure is linear data structure?

a) Trees

b) Graphs

c) Arrays

d) None of above

 

Q11. The operation of processing each element in the list is known as

a) Sorting

b) Merging

c) Inserting

d) Traversal

 

Q12. Finding the location of the element with a given value is:

a) Traversal

b) Search

c) Sort

d) None of above 

 

Q13. Arrays are best data structures

a) For relatively permanent collections of data

b) For the size of the structure and the data in the structure are constantly changing

c) For both of above situation

d) For none of above situation

 

Q14. Linked lists are best suited

a) For relatively permanent collections of data

b) For the size of the structure and the data in the structure are constantly changing

c) For both of above situation

d) For none of above situation

 

Q15. Each array declaration need not give, implicitly or explicitly, the information about

a) The name of array

b) The data type of array

c) The first data from the set to be stored

d) The index set of the array

 

Q16. The elements of an array are stored successively in memory cells because

a) By this way computer can keep track only the address of the first element and the

addresses of other elements can be calculated

b) The architecture of computer memory does not allow arrays to store other than serially

c) Both of above

d) None of above

 

Q17. When determining the efficiency of algorithm, the space factor is measured by

a) Counting the maximum memory needed by the algorithm

b) Counting the minimum memory needed by the algorithm

c) Counting the average memory needed by the algorithm

d) Counting the maximum disk space needed by the algorithm

 

Q18. The complexity of Bubble sort algorithm is

a) O(n)

b) O(log n)

c) O(n2)

d) O(n log n) 

 

Q19. Linked lists are best suited

a) For relatively permanent collections of data

b) For the size of the structure and the data in the structure are constantly changing

c) For both of above situation

d) For none of above situation

 

Q20. If the values of a variable in one module are indirectly changed by another module, this situation is called

a) Internal change

b) Inter-module change

c) Side effect

d) Side-module update 

 

Part 5: List for questions and answers of Data Structures & Algorithms

 

Q1. Answer: d

 

Q2. Answer: a

 

Q3. Answer: a

 

Q4. Answer: a

 

Q5. Answer: b

 

Q6. Answer: c

 

Q7. Answer: d

 

Q8. Answer: c

 

Q9. Answer: d

 

Q10. Answer: c

 

Q11. Answer: d

 

Q12. Answer: b

 

Q13. Answer: a

 

Q14. Answer: b

 

Q15. Answer: c

 

Q16. Answer: a

 

Q17. Answer: a

 

Q18. Answer: b

 

Q19. Answer: b

 

Q20. Answer: c