Probability Engine · CSC206

Data Structures and Algorithms (BSc CSIT, CSC206): the questions likely to come

20 analyzed questions from 7 past papers (2074-2081), grouped by syllabus unit — each with its probability, how often it's been asked, and where to study the answer.

7
Papers analyzed
2074-2081
20
Analyzed questions
across 7 syllabus units
6
Very likely units
high-probability topics
5
Units = 80% of marks
study these first
Model answers for this subject are being written. Every question links to its original paper so you can study from the source meanwhile.
Pick a unit
U5 · Q1/4 · 208110 marks
Sorting

Explain merge sort with its algorithm. Sort the list 38, 27, 43, 3, 9, 82, 10 using merge sort showing all the intermediate steps and analyze its complexity.

61%
Likely to appearAppeared in 4 of the last 4 board papers
Seen in
How well do you know this?rating moves you on
MODEL ANSWERU5 · 10 marks

Merge Sort

Merge sort is a divide-and-conquer sorting algorithm. It recursively divides the list into two halves, sorts each half, and then merges the two sorted halves into a single sorted list.

Algorithm

MERGE-SORT(A, low, high)
  if low < high
     mid = (low + high) / 2
     MERGE-SORT(A, low, mid)        // sort left half
     MERGE-SORT(A, mid+1, high)     // sort right half
     MERGE(A, low, mid, high)       // merge the two halves

MERGE(A, low, mid, high)
  copy A[low..mid] into L and A[mid+1..high] into R
  i = 0, j = 0, k = low
  while i < |L| and j < |R|
     if L[i] <= R[j]: A[k++] = L[i++]
     else:            A[k++] = R[j++]
  copy any remaining elements of L and R into A

Sorting 38, 27, 43, 3, 9, 82, 10

Divide (split until single elements):

[38, 27, 43, 3, 9, 82, 10]
[38, 27, 43, 3]            [9, 82, 10]
[38, 27]   [43, 3]        [9, 82]   [10]
[38] [27]  [43] [3]       [9] [82]  [10]

Conquer (merge back, sorted):

[38] + [27]  -> [27, 38]
[43] + [3]   -> [3, 43]
[27,38] + [3,43] -> [3, 27, 38, 43]

[9] + [82]   -> [9, 82]
[9,82] + [10] -> [9, 10, 82]

[3,27,38,43] + [9,10,82] -> [3, 9, 10, 27, 38, 43, 82]

Sorted output: 3,9,10,27,38,43,823, 9, 10, 27, 38, 43, 82

Complexity Analysis

The recurrence is:

T(n)=2T(n/2)+Θ(n)T(n) = 2T(n/2) + \Theta(n)

By the Master Theorem (a=2,b=2,f(n)=Θ(n)a=2, b=2, f(n)=\Theta(n), so nlogba=nn^{\log_b a} = n):

T(n)=Θ(nlogn)T(n) = \Theta(n \log n)
CaseTime
BestO(nlogn)O(n \log n)
AverageO(nlogn)O(n \log n)
WorstO(nlogn)O(n \log n)

Space complexity: O(n)O(n) for the auxiliary arrays. Merge sort is stable but not in-place.

AI-generated answer · unverifiedView in 2081 paper →
U5 · Question 1 of 4
Question Priority · U5ranked by appearance likelihood — study top-down

Sorting

Analyzed next71%
1
★ TOP PICK

Explain merge sort with its algorithm. Sort the list 38, 27, 43, 3, 9, 82, 10 using merge sort showing all the intermediate steps and analyze its complexity.

10 marksSEEN IN
61%
2

What is sorting? Explain the working mechanism of quick sort algorithm with a suitable example. Analyze its best-case and worst-case time complexity.

10 marksSEEN IN
45%
3

Explain heap sort algorithm with an example and analyze its time complexity.

5 marksSEEN IN
71%
4

Differentiate between bubble sort and selection sort with examples.

5 marksSEEN IN
64%
03The mock

Sit a probable paper

A full mock exam built from the most likely questions, mirroring the real paper's structure. Every slot is a real past question.

Most Probable Paper

Mirrors the real structure · 60 marks · based on 7 past papers

Section A: Long Answer QuestionsAttempt any TWO questions.
  1. 1.

    Explain merge sort with its algorithm. Sort the list 38, 27, 43, 3, 9, 82, 10 using merge sort showing all the intermediate steps and analyze its complexity.

    [10 marks]
    SortingVery likelyfrom 2081 paper →

    This question has recurred in 4 of 7 years; so far only in internal assessments, not the board; and its topic (Sorting) appears in 100% of years.

  2. 2.

    What is a graph? Explain Breadth First Search (BFS) and Depth First Search (DFS) traversal techniques with suitable examples and their applications.

    [10 marks]
    GraphsVery likelyfrom 2080 paper →

    This question has recurred in 4 of 7 years; so far only in internal assessments, not the board; and its topic (Graphs) appears in 100% of years.

  3. 3.

    What is sorting? Explain the working mechanism of quick sort algorithm with a suitable example. Analyze its best-case and worst-case time complexity.

    [10 marks]
    SortingVery likelyfrom 2079 paper →

    This question has recurred in 3 of 7 years; so far only in internal assessments, not the board; and its topic (Sorting) appears in 100% of years.

Section B: Short Answer QuestionsAttempt any EIGHT questions.
  1. 1.

    Explain different representations of a graph (adjacency matrix and adjacency list) with examples.

    [5 marks]
    GraphsVery likelyfrom 2081 paper →

    This question has recurred in 6 of 7 years; so far only in internal assessments, not the board; and its topic (Graphs) appears in 100% of years.

  2. 2.

    What is a heap? Explain the heapify operation and construct a max-heap from 4, 10, 3, 5, 1.

    [5 marks]
    TreesVery likelyfrom 2081 paper →

    This question has recurred in 6 of 7 years; so far only in internal assessments, not the board; and its topic (Trees) appears in 100% of years.

  3. 3.

    Compare linear search and binary search. Write an algorithm for binary search and analyze its complexity.

    [5 marks]
    SearchingVery likelyfrom 2081 paper →

    This question has recurred in 6 of 7 years; so far only in internal assessments, not the board; and its topic (Searching) appears in 100% of years.

  4. 4.

    Explain heap sort algorithm with an example and analyze its time complexity.

    [5 marks]
    SortingVery likelyfrom 2081 paper →

    This question has recurred in 5 of 7 years; so far only in internal assessments, not the board; and its topic (Sorting) appears in 100% of years.

  5. 5.

    Differentiate between bubble sort and selection sort with examples.

    [5 marks]
    SortingVery likelyfrom 2080 paper →

    This question has recurred in 5 of 7 years; so far only in internal assessments, not the board; and its topic (Sorting) appears in 100% of years.

  6. 6.

    What are the applications of stack? Explain how a stack is used in function calls.

    [5 marks]
    The Stack and QueueVery likelyfrom 2081 paper →

    This question has recurred in 5 of 7 years; so far only in internal assessments, not the board; and its topic (The Stack and Queue) appears in 100% of years.

  7. 7.

    Define a queue. Explain circular queue and write an algorithm for its enqueue and dequeue operations.

    [5 marks]
    The Stack and QueueVery likelyfrom 2081 paper →

    This question has recurred in 5 of 7 years; so far only in internal assessments, not the board; and its topic (The Stack and Queue) appears in 100% of years.

  8. 8.

    What is recursion? Write a recursive algorithm to compute the factorial of a number and explain the role of the stack in recursion.

    [5 marks]
    The Stack and QueueVery likelyfrom 2080 paper →

    This question has recurred in 5 of 7 years; so far only in internal assessments, not the board; and its topic (The Stack and Queue) appears in 100% of years.

  9. 9.

    Explain inorder, preorder and postorder tree traversals with an example binary tree.

    [5 marks]
    TreesVery likelyfrom 2080 paper →

    This question has recurred in 5 of 7 years; so far only in internal assessments, not the board; and its topic (Trees) appears in 100% of years.

04The receipts

Behind the numbers

The raw evidence the predictions are computed from: marks per unit per year, syllabus weights, trends, and coverage.

Show the heatmap, topic table and coverage analysis

The receipt: marks per unit, per year

Each row is a syllabus unit, each column an exam year, each cell the marks that unit earned that year. Click any cell to see the actual questions behind it.

Marks:nonefew → many
2074
2075
2077
2078
2079
2080
2081
Total
U5Sorting
120
U7Graphs
100
U2The Stack and Queue
95
U4Trees
95
U1Concept of Data Structure
50
U6Searching
40
U3The List
25
#Syllabus unitProbabilityAppearedAvg marksSyllabus weightExam vs syllabusTrendQuestions
1U5SortingVery likely100%17.113%6 lecture hrsOver-examinedexam 23% · syllabus 13%Steady4 recurring4 total
2U7GraphsVery likely100%14.313%6 lecture hrsOver-examinedexam 19% · syllabus 13%Steady3 recurring3 total
3U2The Stack and QueueVery likely100%13.618%8 lecture hrsBalancedexam 18% · syllabus 18%Steady4 recurring4 total
4U4TreesVery likely100%13.620%9 lecture hrsBalancedexam 18% · syllabus 20%Steady4 recurring4 total
5U1Concept of Data StructureVery likely100%7.19%4 lecture hrsBalancedexam 10% · syllabus 9%Steady2 recurring2 total
6U6SearchingVery likely100%5.79%4 lecture hrsBalancedexam 8% · syllabus 9%Steady1 recurring2 total
7U3The ListLikely71%518%8 lecture hrsUnder-examinedexam 5% · syllabus 18%Steady1 recurring1 total

Study smart, not hard

Drag the slider: studying the top 5 units in priority order covers ~88% of all observed marks.

  1. ~80% line

Lecture time vs exam marks

Where the exam pays more than the curriculum spends: ● lectures vs ● exam marks, as a share of the whole course. A long teal-leading bar = high-yield unit.

U5Sorting
13% of lectures → 23% of markshigh yield
U7Graphs
13% of lectures → 19% of markshigh yield
U2The Stack and Queue
18% of lectures → 18% of marks
U4Trees
20% of lectures → 18% of marks
U1Concept of Data Structure
9% of lectures → 10% of marks
U6Searching
9% of lectures → 8% of marks
U3The List
18% of lectures → 5% of markslow yield

Topics are the official CSC206 syllabus units. Predictions are data-driven probabilities computed from 7 past papers (2074-2081) by mapping each real question to its syllabus unit. They indicate what has historically been likely, not guaranteed questions. Always study the full syllabus.