Sample Paper_CS301P.pdf

Verified academic study resource for CS301 (Data Structures) under the Computer Science at Virtual University of Pakistan. This PDF document (Mega Solved MCQs Question Bank) covers Full Course Curriculum spanning approximately 180 pages across 8 curriculum modules, and is indexed for student examination review with instant in-browser preview and 100% free direct download.

Course
CS301 – Data Structures
Faculty
Computer Science
Format
PDF
Type
MCQ Bank
Coverage
Full Course Curriculum

Cross-verify solutions against official lecture handouts. Practice active recall before checking answers to ensure true concept retention.

What this file covers — CS301 syllabus roadmap

  1. Core Architecture, Syntax & Primitive Data Structures — Lectures 1 to 6 (Pages 1 to 65). 15% Objective Marks (8–10 MCQs)
  2. Conditional Branching, Loops & Logical Control Flow — Lectures 7 to 12 (Pages 66 to 140). 18% Exam Marks (MCQs + 2-Mark Short Questions)
  3. Memory Management, Pointers, Arrays & Functions — Lectures 13 to 18 (Pages 141 to 215). 22% Exam Marks (High Yield for Midterms)
  4. Midterm Consolidation, Strings & Algorithm Synthesis — Lectures 19 to 22 (Pages 216 to 280). Midterm Exam Culmination (Lectures 1–22 Scope)
  5. Object-Oriented Paradigms: Classes & Data Abstraction — Lectures 23 to 29 (Pages 281 to 360). 16% Final-Term Marks (Core OO Concepts)
  6. Inheritance Hierarchies & Dynamic Polymorphism — Lectures 30 to 36 (Pages 361 to 435). 20% Final-Term Marks (Virtual Functions & V-Tables)
  7. Templates, Standard Library & Persistent File I/O — Lectures 37 to 41 (Pages 436 to 510). 14% Final-Term Marks (Generic Code & Streams)
  8. Final-Term Examination Dossier & Capstone Synthesis — Lectures 42 to 45 (Pages 511 to 585). Final-Term Exam Synthesis (Lectures 23–45 Scope)

Frequently asked questions

Where can I download Sample Paper_CS301P.pdf for free?

You can preview and download "Sample Paper_CS301P.pdf" (CS301 PDF, ~180 pages) directly from the MIHORA VU Study Library (https://study.mihora.tech/doc/sample-paper-cs301p-pdf) with 100% free high-speed downloads and zero registration requirements.

What syllabus chapters and lectures are covered in this CS301 file?

This document covers Full Course Curriculum across 8 distinct lecture units (Lectures 1 to 6, Lectures 7 to 12, Lectures 13 to 18, Lectures 19 to 22, Lectures 23 to 29, Lectures 30 to 36, Lectures 37 to 41, Lectures 42 to 45), featuring comprehensive definitions, solved objective questions, and examiner marking rubrics.

What is the passing criteria for CS301 under the VU 20% Two-Half Rule?

Under official Virtual University regulations, students must score at least 20% in the First Half (Quizzes, Assignments, GDBs, and Midterm combined) AND independently at least 20% in the Final-Term examination paper. Scoring under 20% in the final exam results in an automatic F grade regardless of earlier marks.

Are CS301 solved past papers and handouts verified for 2026 exams?

Yes. All CS301 materials on MIHORA VU—including Moaaz, Waqar Siddhu, and team archives—are reviewed against the current VU syllabus to help students prepare for 2026 Midterm, Final-Term, and online quiz examinations.

Inside this file

                                   Sample Paper
                            FINALTERM EXAMINATION
                                     Fall 2022
                          CS301P - Data Structures Practical

                                                                         Time: 90 min
                                                                            Marks: 40

Question No: 1      (Marks: 01) - Please choose the correct option

What is the main advantage of linked lists over arrays?
a. Dynamic size
b. Faster indexing
c. Better cache performance
d. Constant time insertion and deletion

Question No: 2      (Marks: 01) - Please choose the correct option

How do you find the middle node in a linked list?
a. By dividing the size of the linked list by 2
b. By starting from the head node and traversing half of the list
c. By starting from the tail node and traversing half of the list
d. By randomly selecting a node

Question No: 3      (Marks: 01) - Please choose the correct option

What is the time complexity of accessing an element in a stack implemented using an
array?
a. O(1)
b. O(n)
c. O(log n)
d. O(n log n)

Question No: 4      (Marks: 01) - Please choose the correct option

What is an underflow condition in a stack?
a. When the stack is empty and an element is popped
b. When the stack is full and an element is pushed
c. When the stack is not full but an element is not pushed
d. When the stack is not empty but an element is not popped

Question No: 5      (Marks: 01) - Please choose the correct option

What is the use of a queue in computer science?
a. To store and retrieve elements in a sequential manner
b. To store and retrieve elements in a random manner
c. To store and retrieve elements in a fixed order
d. To store and retrieve elements in a reversed order

Question No: 6      (Marks: 01) - Please choose the correct option

If the elements “A”, “B”, “C” and “D” are placed in a queue and are deleted one at a time,
in what order will they be removed?
a) ABCD
b) DCBA
c) DCAB
d) ABDC

Question No: 7     (Marks: 01) - Please choose the correct option

What is a node in a tree that has no children called?
a. Leaf node
b. Root node
c. Parent node
d. Child node

Question No: 8     (Marks: 01) - Please choose the correct option

What is a degenerate tree?
a. A binary tree that is always balanced
b. A binary tree that is never balanced
c. A binary tree where all nodes have only one child
d. A binary tree where all nodes have two children

Question No: 9     (Marks: 01) - Please choose the correct option

Which of the following traversal outputs the data in sorted order in a BST?
a. Inorder
b. Pre order
c. Post order
d. Level Order

Question No: 10     (Marks: 01) - Please choose the correct option

While inserting the elements 71, 65, 84, 69, 67, 83 in an empty binary search tree (BST)
in the sequence shown, the element in the lowest level is:
a. 65
b. 67
c. 69
d. 83

Question No: 11     (Marks: 01) - Please choose the correct option

How are reference variables created in programming?
a. By declaring a variable with the reference type
b. By declaring a variable with the primitive type
c. By calling a constructor
d. By initializing a variable with a value

Question No: 12    (Marks: 01) - Please choose the correct option

What happens when a constant variable is assigned a new value in programming?
a. The value of the constant variable is changed
b. The constant variable retains its old value
c. A compile-time error occurs
d. A runtime error occurs

Question No: 13    (Marks: 01) - Please choose the correct option

If values 20,30,25 are used to build AVL tree then which type of rotation can balance the
AVL tree?
    a) Double left-right
    b) Double right-left
    c) Single right
    d) Single left

Question No: 14     (Marks: 01) - Please choose the correct option

In the given BST, the balance factor of root node is:

   a) 0
   b) -1
   c) 2
   d) -2

Question No: 15     (Marks: 01) - Please choose the correct option

The ASCII value for character ‘C is:
   a) 65
   b) 66
   c) 67
   d) 68
Question No: 16 (Marks: 01) - Please choose the correct option

In Huffman coding, data in a tree always occur?
a) roots
b) leaves
c) left sub trees
d) right sub trees

Question No: 17     (Marks: 01) - Please choose the correct option

Consider the max heap represented by the following array. Which of the following is the
parent of node 19?

55,45,35,25,30,31,32,23,19

   a) 25
   b) 35
   c) 45
   d) 55

Question No: 18     (Marks: 01) - Please choose the correct option

Consider a min heap, represented by the following array:

15,16,18,19,17,20

After deleting the root node. Which of the following is the updated min heap?

   a) 16,17,18,19,20
   b) 16,17,19,18,20
   c) 16,20,17,19,18
   d) 16,20,18,19,20

Question No: 19     (Marks: 01) - Please choose the correct option

 In a max-heap, element with the greatest key is always in the which node?
a) Leaf node
b) First node of left sub tree
c) root node
d) First node of right sub tree

Question No: 20     (Marks: 01) - Please choose the correct option

 If we call the union function( 2,3) and then (2,7), the name of set will be,
a) 2
b) 3
c) 7
d) 0

Question No: 21     (Marks: 01) - Please choose the correct option

Suppose in a hashing technique, we have the key and hash function given below:
Key = 20
Hash function = key / 10
At which array index, the key will be stored?

a) 2
b) 3
c) 7
d) 0

Question No: 22 (Marks: 01) - Please choose the correct option

If Hash function = key %10, so far which of the pair of values, the collision take place?

a) 12 and 2
b) 14 and 15
c) 11 and 22
d) 1 and 10

Question No: 23 (Marks: 01) - Please choose the correct option

Here is an array of ten integers 15 13 18 19 11 17 10 12 16 14
Array after the FIRST iteration of the main loop in selection sort algorithm will be
(sorting from smallest to largest)

a) 10 13       18   19   11   17    15    12 16 14
b) 10 13       18   19   11   17    12    15 16 14
c) 13 10       18   19   11   17    12    15 16 14
d) 13 18       10   19   11   17    12    15 16 14

More CS301 files

All CS301 files · Midterm Prep 2026 · MCQs Bank