Skip to content
VUBuddy

CS502 Quiz 1 Lectures 1-10 by Junaid

Fundamentals of Algorithms PDF 1.8 MBUpdated 23 Oct 2026
Quiz CS502 Quiz 1 Lectures 1-10 by Junaid PDF 1.8 MB
vubuddy.com
Type
Quiz
Course
CS502 Fundamentals of Algorithms
Size
PDF 1.8 MB
Updated
23 Oct 2026
Free download 0 of 3 used today
Download free · 1.8 MB

You get 3 free files a day on the website. Add the Chrome extension for 30 a day.

Unlimited downloads in the Android app Get it free on Google Play

Preview text

Text from pages 2, 3, 4 of 33. Download the file for all 33 pages.

  1. In heap sort algorithm, the total running time for heavily procedure is
  2. Quick sort algorithm is required a lot of comparison in the ____ condition.
  •  Worse case
  •  Best and average case
  •  Average case
  •  Best case
  1. In heap sort algorithm (using max heap). When every time maximum element is removed from top.
  •  Divide and conquer strategy helps us
  •  We are left with a lot
  •  We call merge sort algorithm
  •  It becomes order n2 algorithm
  1. In average-case time analysis of quick sort algorithm, The most balanced case for partition is where we divide the list of element into ________
  •  Three nearly equal pieces
  •  Single piece exactly
  •  Two nearly piece
  •  Equal no. of piece as of input element
  1. Consider three matrices X,Y,Z dimensions 1×2.2×.3×4 respectively. The number of multiplication of (XYZ) is:
  •  32
  •  30
  •  24
  •  18
  1. Quicksort is a/an _____ and______ sorting algorithm.
  •  In-place, not stable one
  •  Not in-place, stable one
  •  In-place, stable one
  •  Not in-place, not stable one
  1. ________items are not allowed in the 0/1 knapack.
  •  Lighter
  •  Whole
  •  Weighty
  •  Fractional
  1. The main purpose of mathematical analysis is measuring the ______ required by the algorithm.
  •  Space
  •  Execution time and memory
  •  Input & output
  •  Execution time
  1. Execution time of an algorithm can be measured by __________.
  •  Divide and conquer approach
  •  Both brute force and divide and conquer approach
  •  Mathematical analysis
  •  Brute force approach
  1. Quick sort is based on ________ strategy.
  •  Graph theory
  •  Divide-and-conquer
  •  Dynamic programming
  1. A sorting algorithm is called as ______ if duplicate element remain in the same relative position after sorting.
  •  O(n) algorithm
  •  Stable
  •  Parallel
  •  Complex

Q12. Which one sorting algorithm is best suited to sort an array of 2 million elements?

  •  Insert sort
  •  Quick sort
  •  Merge sort
  •  Bubble sort
  1. We can use the ___________ property to devise a recursive formulation of the edit distance problem.
  •  Algorithm
  •  Small substructure
  •  Optimal substructure
  •  Real
  1. While sorting. The ordered domain means for any two input elements x and y ________ satisfies only.
  •  All of the above
  •  x > y
  •  x < y
  •  x = y
  1. 8n2 + 2n -3 will eventually exceed c2*(n) no matter how large we make _____.
  •  2n
  •  n
  •  this equation
  •  c2
  1. ________ is a method of solving a problem in which we check all possible solution to the problem to find the solution we need.
  •  Sorting algorithm
  •  Plane-sweep algorithm
  •  Brute-force algorithm
All CS502 files →
CS502 Fundamentals of Algorithms All CS502 handouts, past papers, quizzes and MCQs in one place. Open course page

Get more out of VUBuddy, for free

Android app Free on Google Play
  • Unlimited downloads
  • The explanation behind every MCQ answer
  • Study offline on slow data
Get the Android app
Chrome extension Free on the Chrome Web Store
  • 30 downloads a day instead of 3
  • Sign in and buy Pro Semester here
Add to Chrome

One Pro Semester membership works in both the extension and the app.