DATA1002/1902: Week 13 - Practice Questions
Room Number
_____________________
Seat Number
_____________________
Student Number
_____________________
ANONYMOUSLY MARKED
(Please do not write your name on this exam paper)
PRACTICE EXAM PAPER
This paper is not to be removed from the exam venue
Computer Science
EXAMINATION
Semester 2 - Practice, 2025
DATA10/902 Informatics: Data and Computation
EXAM WRITING TIME:
2 hours
READING TIME:
10 minutes
EXAM CONDITIONS:
This is a CLOSED book exam - no material permitted
MATERIALS PERMITTED IN THE EXAM VENUE:
(No electronic aids are permitted e.g. laptops, phones)
Calculator - programmable
MATERIALS TO BE SUPPLIED TO STUDENTS:
Answer sheet: Gradescope MCQ (single-sided - 100 Qs)
INSTRUCTIONS TO STUDENTS:
For Examiner Use Only
Q
Total
Please tick the box to confirm that your examination paper is complete.
Mark
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
________
DATA1002/1902: Week 13 - Practice Questions
[Multiple-Choice Section] Each question carries 2 marks. All choices should be filled in on
the provided answer sheet for the MCQs. No explanation is required.
Q1. Which concept involves introducing random errors into data to protect privacy?
A) Data perturbation
B) Anonymization
C) Data aggregation
D) Data quality enhancement
Q2. What is the meaning of k in k-Means algorithm?
A) number of data points
B) maximum number of iterations
C) number of clusters
D) number of features
Q3. Which of the following is NOT a step in data cleaning?
A) Detecting the problem
B) Ignoring missing values
C) Trying to remedy the problem
D) Building automated tools for transformation
Q4. Which approach involves replacing missing values with the most common value for that
a5ribute among the data?
A) Impute a value
B) Remove the whole item
C) Treat default as missing
D) Treat incorrect value as missing
Q5. You standardise a numeric feature x by transforming to (x − μ)/σ. What is true
afterwards?
A) Mean≈0, variance≈1
B) Mean≈1, variance≈0
C) Mean≈0, variance≈2
D) Mean≈1, variance≈0
Q6. Which file format best preserves nested key–value structure with arrays?
A) CSV
B) JSON
C) TXT
D) SET
Q7. In k-fold cross-validation with k=5, which is true?
A) Each fold is used exactly once for training
B) Each fold is used exactly once for validation
C) The validation score generally increases as k decreases (all else equal)
D) The method cannot be used for classification
DATA1002/1902: Week 13 - Practice Questions
Q8. In a decision tree, what do the leaf nodes represent?
A) Feature scaling steps
B) class predictions
C) Hyperparameters of the model
D) Training/validation splits
Q9. In Python, what is the type of the value produced by set([1, 2, 2, 3])?
A) List
B) Tuple
C) Set
D) dict
Q10. You have a binary classifier that outputs a probability 𝑝𝑝. A case is predicted positive if
𝑝𝑝 ≥ 𝜏𝜏(the decision threshold 𝜏𝜏). The current confusion matrix shows many false positives
and few false negatives. [this is a challenging question]
Holding the model and data fixed, which change to 𝜏𝜏will reduce false positives?
A) Lower 𝜏𝜏
B) Raise 𝜏𝜏
C) Randomize predictions
D) Add more features without retraining
DATA1002/1902: Week 13 - Practice Questions
[Short Essay Section] Each question carries 10 marks. Write your answers in the boxes
provided below each question.
Q11 [10pts].
a) Explain the limitations of using accuracy as the sole metric for assessing model
performance.
b) Describe two alternative evaluation metrics that help address the limitations of using
accuracy alone. Explain what each metric means and how it is calculated.
Q12 [10pts]. You are given a customer review dataset for analysis. Each row contains the
following columns: Customer, Product, Rating (a number from 1 to 5), Last Modified Date
During your initial review, you observe:
• Some rows have missing values in the Rating column
• Some customers have submitted multiple reviews for the same product, with
conflicting ratings. In those cases, the Last Modified Date differs between entries
Describe a structured plan for cleaning and preparing this dataset for analysis. Your answer
should include the key strategies you would follow to assess and clean the dataset. Explain
the potential negative influence associated with the strategies.
DATA1002/1902: Week 13 - Practice Questions
Q13 [10pts]. You are working with a dataset from a chain of coffee shops that includes:
• Daily sales revenue for each shop over the past 12 months
• Average monthly revenue per city
You are preparing a report for senior management to highlight trends and comparisons.
a) You want to show how sales revenue has changed over time for one shop.
How would you design the chart? What would be on the x-axis and y-axis? Explain why this
chart is suitable.
b) You want to compare the average monthly revenue across cities.
What type of chart would be best for this comparison? How would you design the chart?
What would be on the x-axis and y-axis? Explain why this chart is suitable.
DATA1002/1902: Week 13 - Practice Questions
Q14 [10pts].
a) Define overfitting and underfitting. Describe how training and validation accuracies
typically behave in each case.
b) A telecommunications company uses a logistic regression model whether a customer will
leave the service. The input features include customer attributes such as tenure, monthly
charges, contract type, number of customer service calls, and internet service type. The
binary output is 1 if the customer churns, 0 otherwise. After training the model, the team
observes that the training accuracy is much higher than the validation accuracy. Explain this
is caused by overfitting or underfitting. Propose a potential solution to address it.
DATA1002/1902: Week 13 - Practice Questions
[Short Essay Section on Advanced Material (Data1902 only)] Each question carries 10
marks. Write your answers in the boxes provided below each question.
Q15 [10 pts].
Consider the following function:
def max_subarray(nums):
max_sum = current_sum = nums[0]
for num in nums[1:]:
current_sum = max(num, current_sum + num)
max_sum = max(max_sum, current_sum)
return max_sum def max_subarray(nums):
max_sum = current_sum = nums[0]
for num in nums[1:]:
current_sum = max(num, current_sum + num)
max_sum = max(max_sum, current_sum)
return max_sum
a) Explain in your own words how the function works.
b) What is the time complexity of this function in Big O notation and why?
DATA1002/1902: Week 13 - Practice Questions
USE THIS SPACE FOR ADDITIONAL ANSWER SPACE IF NEEDED, PLEASE
ENSURE YOU INDICATE WHICH QUESTION YOU ARE ANSWERING.
DATA1002/1902: Week 13 - Practice Questions
USE THIS SPACE FOR ADDITIONAL ANSWER SPACE IF NEEDED, PLEASE
ENSURE YOU INDICATE WHICH QUESTION YOU ARE ANSWERING.
END OF EXAMINATION