- Type
- Midterm past paper
- Course
- CS505 Virtual Systems and Services
- Size
- PDF 688 KB
- Updated
- 23 Oct 2026
You get 3 free files a day on the website. Add the Chrome extensionSign in with the extension for 30 a day.
Preview text
Text from pages 2, 3, 4 of 18. Download the file for all 18 pages.
Q1. Which of the following is a correct definition of an algorithm? a) A sequence of steps to solve a problem
Answer: A) A programming language A sequence of steps to solve a problem
Q2. Which of the following is NOT a characteristic of a good algorithm? a) Finiteness
Answer: C) Efficiency Infinite loops
Q3. Which of the following sorting algorithms has the best worst-case time complexity? a) Bubble sort
Answer: C) Selection sort Merge sort
Q4. Which of the following is true about Big O notation? a) It measures the best-case time complexity.
Answer: B) It is used to determine memory usage. It measures the worst-case time complexity.
Q5. Which data structure uses LIFO (Last In, First Out) order? a) Queue
Answer: B) Linked list Stack
Q6. Which of the following is the correct order of complexity from best to worst? a) O(n), O(log n), O(n^2)
Answer: C) O(n), O(n^2), O(log n) O(log n), O(n), O(n^2)
Q7. Which of the following is the best-case time complexity for Quick Sort? a) O(n^2)
Answer: B) O(n) O(n log n)
Q8. Which of the following is the primary purpose of a hash function? a) To sort the data
Answer: B) To find the maximum value To map data to a fixed-size value
Q9. What does BFS (Breadth-First Search) explore first in a graph? a) The deepest node
Answer: B) The most distant node The nodes closest to the starting point
Q10. Which of the following is an example of a divide and conquer algorithm? a) Merge Sort
Answer: A) Bubble Sort Merge Sort
Q11. Which of the following operations is performed in constant time? a) Inserting an element into a linked list
Answer: C) Inserting an element into a balanced tree Accessing an element by index in an array
Q12. Which of the following is a feature of a Binary Search Tree (BST)? a) Each node has two children with equal value
Answer: B) The left child is greater than the parent node Nodes are arranged in increasing order
Related CS505 files
All CS505 files →- CS505 Final Term Highlighted Slides Set 2 by Alishba Highlighted PDF 11.7 MB
- CS505 Quiz 4 Jan 2026 by Lucky Quiz PDF 361 KB
- CS505 Final Term Current Paper 2022 Final term PDF 340 KB
- CS505 Final Term Solved Subjective by MS Team Final term PDF 716 KB
- CS505 Final Term Past Paper Feb 2024 Final term PDF 418 KB
- CS505 Final Term MCQs by Yasir Ejaz Final term PDF 1.4 MB
Get more out of VUBuddy, for free
- Unlimited downloads
- The explanation behind every MCQ answer
- Study offline on slow data
- 30 downloads a day instead of 3
- Sign in and buy Pro Semester here
One Pro Semester membership works in both the extension and the app.