Start learning →

MCA Sorting and Searching — practice questions

Explore 32 free Sorting and Searching questions in MCA Computer Science. Open each question or exercise to read its content, reference answers and available explanation.

Practise Sorting and Searching with Quill →

Sorting and Searching questions and exercises with answers

Showing questions 1–30 of 32.

Locating a particular element in a collection is called:Read the answer and worked solution →Every iteration through each element of a list is called a:Read the answer and worked solution →Changing the positions of two elements with each other is called:Read the answer and worked solution →Linear search is also called serial search or:Read the answer and worked solution →In binary search, the key is first compared with the element in the:Read the answer and worked solution →Which sort repeatedly compares adjacent elements and swaps them if unordered?Read the answer and worked solution →The item being searched for is usually referred to as the:Read the answer and worked solution →The first element in a list has which index value?Read the answer and worked solution →For a list of n elements, bubble sort makes how many passes?Read the answer and worked solution →In ascending bubble sort, which element is placed correctly after each pass?Read the answer and worked solution →If no swapping happens in a pass, it means the list is already:Read the answer and worked solution →In ascending selection sort, the first pass finds which element?Read the answer and worked solution →In selection sort, the smallest element is swapped with which element?Read the answer and worked solution →Insertion sort divides the list into how many parts?Read the answer and worked solution →Linear search is described as which kind of technique?Read the answer and worked solution →If the key is the first element, how many comparisons does linear search make?Read the answer and worked solution →If the key is the last element, how many comparisons does linear search make?Read the answer and worked solution →If the key is absent, how many comparisons does linear search make?Read the answer and worked solution →In binary search, if the middle element is greater than the key, search the:Read the answer and worked solution →In binary search, if the middle element is less than the key, search the:Read the answer and worked solution →Each unsuccessful comparison in binary search reduces the remaining elements by:Read the answer and worked solution →Binary search needs only one iteration when the key is which value?Read the answer and worked solution →Binary search is more efficient than linear search only if the list is:Read the answer and worked solution →Bubble, selection and insertion sort all have a time complexity of:Read the answer and worked solution →Linear or binary searchRead the answer and worked solution →Match the sorting methodRead the answer and worked solution →Order one binary search stepRead the answer and worked solution →Count the comparisonsRead the answer and worked solution →True or false about sortingRead the answer and worked solution →One word is wrongRead the answer and worked solution →

Worked practice questions

Locating a particular element in a collection is called:

  1. Searching
  2. Switching
  3. Sketching
  4. Stretching
Show answer and solution

Correct answer: A. Searching

1. A collection is of little use if an item cannot be found in it. 2. The act of finding it has a name. 3. Searching means locating a particular element in a collection of elements. 4. So the answer is searching. _Source: syllabus Computer Science, Ch 5 'Sorting' and Ch 6 'Searching'_

Open this question →

Every iteration through each element of a list is called a:

  1. Panel
  2. Pass
  3. Path
  4. Patch
Show answer and solution

Correct answer: B. Pass

1. A sorting algorithm sweeps the list repeatedly. 2. Each complete sweep is named. 3. Every iteration through each element of a list is called a pass. 4. So the answer is a pass. _Source: syllabus Computer Science, Ch 5 'Sorting' and Ch 6 'Searching'_

Open this question →

Changing the positions of two elements with each other is called:

  1. Sampling
  2. Stamping
  3. Swapping
  4. Sweeping
Show answer and solution

Correct answer: C. Swapping

1. Sorting works by moving elements past one another. 2. The basic move exchanges two of them. 3. Swapping two elements means changing their positions with each other. 4. So the answer is swapping. _Source: syllabus Computer Science, Ch 5 'Sorting' and Ch 6 'Searching'_

Open this question →

How to practise

  1. Choose a Sorting and Searching question and try to work out your answer.
  2. Open the question to check the correct answer and read its worked solution.
  3. Continue in the app for bite-sized lessons, explanations and review with Quill. You can start without creating an account.

More Computer Science topics