Counted from the questions in the past papers listed on this site. Repeated = how many times the topic came in those papers.
Machine Learning for Data Science important questions with answers
Each answer starts with the short answer. Then come the points to write, a diagram and an exam tip. The questions under each topic are copied from the RGPV papers.
Q1. Motivation for machine learning and generalization
Asked 1 time in 2026 · Unit 1
From the papers
“Discuss the motivation for studying Machine Learning and analyze the concept of generalization in Machine Learning systems.” (May 2026)
The short answer
Machine learning (ML) lets a computer learn a rule from examples instead of being given the rule by a programmer. Generalization is the ability of the learned model to give correct answers on new data it has never seen.
Write these points
Motivation: why study ML
Some rules are too hard to write by hand, such as reading handwriting or spotting fraud.
Data is now large. Phones, banks and sensors produce more than any person can study.
Rules change over time. A learned model can be retrained on new data.
ML personalises: recommendations, search and voice assistants.
Cheaper computers and better algorithms made it practical.
Generalization
Training error is the error on data used for learning. Test error is the error on new data.
A model that memorises the training data has a low training error but a high test error. This is overfitting.
A model that is too simple misses the pattern. This is underfitting.
Bias is error from wrong assumptions (too simple). Variance is error from too much sensitivity to the training set (too complex).
Total expected error = bias squared + variance + noise. The aim is the best balance, the bias variance trade off.
How to get good generalization
Keep a separate test set and never train on it.
Use enough data and remove noise.
Choose a model of suitable size. Use regularization.
Use cross validation to compare models.
Spotting overfitting.
A model gets 2 percent error on 1,000 training emails but 15 percent on 300 new emails.
The gap is 15 - 2 = 13 points. A large gap shows overfitting.
A simpler model with 6 percent training error and 8 percent test error generalizes better. Its gap is only 2 points.
Real-life example
A student who learns the answers of last year's paper by heart scores well on that paper only. A student who understands the ideas scores well on any paper. ML wants the second kind of student.
Figure: training error and test error
Same or opposite: overfitting and underfitting
Point
Overfitting
Underfitting
Same or opposite
Training error
Very low
High
Opposite
Test error
High
High
Same
Main cause
Model too complex
Model too simple
Opposite
Fix
More data, regularization
More features, bigger model
Opposite
Exam tip. Define ML and generalization in two lines. Draw the error against complexity curve with training and test error. Add the bias variance point and one numeric example.
“Explain Vapnik-Chervonenkis (VC) Dimension and Probably Approximately Correct (PAC) Learning with suitable examples” (May 2026)
The short answer
The VC dimension of a hypothesis class is the largest number of points it can shatter, that is label in every possible way. PAC learning asks how many examples are enough so that, with high probability, the learned hypothesis has a small error.
Write these points
VC dimension
A class shatters a set of n points if for all 2^n labellings some hypothesis in the class separates them.
VC dimension is the size of the largest set that can be shattered. A bigger number means a more flexible model.
A straight line in a plane has VC dimension 3. It can split any labelling of 3 points but not the 4 point XOR layout.
Axis aligned rectangles have VC dimension 4. Intervals on a line have VC dimension 2.
A high VC dimension needs more data and risks overfitting.
PAC learning
Close to correct: the error is at most epsilon.
Probably: this holds with probability at least 1 - delta.
A learner is PAC if it needs only a number of examples that grows slowly (polynomial) in 1/epsilon and 1/delta.
For a finite hypothesis class H and a hypothesis that fits all training data, the sample size is m >= (1/epsilon) x (ln |H| + ln (1/delta)).
How many examples are enough.
Take |H| = 1,024 hypotheses, epsilon = 0.1 and delta = 0.05.
m >= 10 x (ln 1024 + ln 20) = 10 x (6.93 + 3.00) = 99.3, so 100 examples.
Halve epsilon to 0.05 and the need doubles to about 199 examples.
Remember. The finite class bound above assumes the data are noise free and some hypothesis in H fits them all. Textbooks give other bounds for other settings.
Real-life example
A driving test cannot ask every road situation. If the examiner picks enough random situations and you pass all, it is probably true that you will do well on a new road. PAC learning puts a number on how many tests are enough.
Figure: a line shatters 3 points but not 4
Same or opposite: VC dimension and PAC learning
Point
VC dimension
PAC learning
Same or opposite
Measures
Capacity of a model class
Samples needed for a guarantee
Opposite
Output
A number such as 3
A bound such as m >= 100
Opposite
Connects model size to data size
Yes
Yes
Same
Idea
Shattering points
Probably and nearly correct
Opposite
Exam tip. Define shatter first. Show the 3 points versus 4 points picture for a line. Then write epsilon, delta and the sample size formula with one number example.
Q3. Supervised learning: architecture and workflow
Asked 1 time in 2026 · Unit 2
From the papers
“Define supervised learning and discuss the architecture and workflow of supervised learning models” (May 2026)
The short answer
Supervised learning learns a function from labelled examples, pairs of an input x and the correct output y. The trained model then predicts y for new inputs.
Write these points
Types
Classification: y is a category such as spam or not spam.
Regression: y is a number such as a house price.
Architecture (main parts)
Training data: inputs and labels.
Feature extraction: turn raw data into numbers.
Model (hypothesis): a function with parameters, for example a line or a tree.
Loss function: measures the gap between prediction and label.
Optimizer: changes the parameters to reduce the loss, for example gradient descent.
Evaluation: metrics on data not used for training.
Workflow
Collect and clean data. Split into training, validation and test sets.
Choose a model. Train it. Tune the hyperparameters on the validation set.
Report the final score once on the test set.
Deploy. Watch the performance and retrain when the data changes.
Algorithm
Type
Example use
Linear regression
Regression
Predict price
Logistic regression
Classification
Loan default
Decision tree
Both
Diagnosis rules
SVM
Classification
Text topic
A tiny regression.
Hours studied x = 1, 2, 3, 4, 5 and marks y = 2, 4, 5, 4, 6.
Least squares gives marks = 1.8 + 0.8 x hours. Check: the means are 3 and 4.2, so 4.2 - 0.8 x 3 = 1.8.
For 6 hours the model predicts 1.8 + 0.8 x 6 = 6.6.
Real-life example
A teacher shows a child many fruit pictures with names. After enough examples the child names a new fruit correctly. The pictures with names are the labelled data.
Figure: supervised learning workflow
Same or opposite: supervised and unsupervised learning
Point
Supervised
Unsupervised
Same or opposite
Labels in the data
Yes
No
Opposite
Typical task
Classification, regression
Clustering
Opposite
Learns from examples
Yes
Yes
Same
Measure of success
Error against labels
Cluster quality
Opposite
Exam tip. Define it with the word labelled. Draw the workflow as boxes. Name one classification and one regression example.
Q4. Regression, probabilistic classifiers and ensembles compared
Asked 1 time in 2026 · Unit 2
From the papers
“Evaluate regression techniques, probabilistic classifiers and ensemble learning methods in terms of prediction accuracy and computational efficiency.” (May 2026)
The short answer
Regression models, probabilistic classifiers and ensembles trade accuracy against cost. Simple models are fast, while ensembles are usually the most accurate but cost more.
Write these points
Comparison
Method
Accuracy
Training cost
Prediction cost
Linear regression
Good if the link is linear
Low
Very low
Logistic regression
Good, gives probabilities
Low
Very low
Naive Bayes
Fair, assumes independence
Very low (counting)
Very low
Random forest (bagging)
High, stable
Medium to high
Medium
Boosting
Often highest on tables
High, runs in sequence
Medium
Points to write
Regression: least squares is solved in one step. Easy to read, but weak on curved patterns.
Naive Bayes: needs very little data and time. Wrong when features depend on each other.
Logistic regression: a linear boundary with calibrated probabilities.
Bagging: averages many models on random samples. Reduces variance. Can run in parallel.
Boosting: adds models that fix earlier errors. Reduces bias. Runs one after another and can overfit noise.
How to decide
Start with a simple model as the baseline.
Move to an ensemble only if the gain in accuracy is worth the extra time and memory.
Compare on a validation set with the same split.
Least squares by formula.
Data (1,2), (2,4), (3,5), (4,4), (5,6). Slope = sum of (x - 3)(y - 4.2) / sum of (x - 3)^2 = 8 / 10 = 0.8. Intercept = 1.8.
Sum of squared errors = 2.4. A flexible ensemble would fit the five points closer but may overfit so few data.
Real-life example
To predict tomorrow's electricity use, a quick line through past data is cheap and fine for a rough plan. A grid company that needs every percent would pay for a forest of models that vote.
Figure: which model to try first
Same or opposite: bagging and linear regression
Point
Bagging (forest)
Linear regression
Same or opposite
Prediction accuracy on complex data
Higher
Lower
Opposite
Computation
Heavy
Light
Opposite
Can predict numbers
Yes
Yes
Same
Easy to explain
Harder
Easy
Opposite
Exam tip. Use a table with accuracy and cost columns. Write one line of trade off for each group. End with the advice to start with a simple baseline.
“Explain the Expectation Maximization (EM) algorithm in detail. Discuss its iterative optimization process and applications in probabilistic Machine Learning systems” (May 2026)
The short answer
Expectation Maximization (EM) finds maximum likelihood parameters of a model with hidden variables. It repeats an E step that guesses the hidden values softly and an M step that re estimates the parameters.
Write these points
EM for a Gaussian mixture model (GMM)
Data come from K bell curves with means mu_k, variances s_k^2 and weights pi_k. Which curve made each point is hidden.
Model: p(x) = sum over k of pi_k x N(x | mu_k, s_k^2).
Initialize means, variances and weights.
E step: for each point compute the responsibility r_ik = pi_k N(x_i | k) / sum over j of pi_j N(x_i | j).
M step: N_k = sum of r_ik. New mu_k = sum of r_ik x_i / N_k. New variance from the weighted squared gaps. New pi_k = N_k / n.
Compute the log likelihood. Repeat until it stops rising.
Properties
Each full iteration never lowers the likelihood. It may stop at a local best, so try several starts.
K-means is the hard assignment version of EM with equal round clusters.
Data 1, 2, 4, 7, 8, 10. Start: means 2 and 9, variances 4 and 4, weights 0.5 and 0.5.
E step for x = 4: responsibility 0.932 for curve 1 and 0.068 for curve 2. For x = 7: 0.068 and 0.932.
M step: N = (3.01, 2.99). New means 2.43 and 8.26. New variances 2.11 and 1.98. Weights 0.502 and 0.498.
After a second step the means are 2.34 and 8.31 and they change little, so EM has nearly converged.
Real-life example
A teacher finds two answer sheets mixed with no names. She guesses by handwriting which sheet belongs to which student, says how sure she is, then learns each student's style from her guesses. She repeats until the guesses stop changing. That loop is EM.
Figure: EM on one dimensional data
Same or opposite: E step and M step
Point
E step
M step
Same or opposite
Works on
Hidden variables
Parameters
Opposite
Output
Responsibilities r
New means, variances, weights
Opposite
Repeated until the likelihood settles
Yes
Yes
Same
Uses
Current parameters
Current responsibilities
Opposite
Exam tip. Name the GMM model. Write the E step and the M step formulas. Add the small numeric run to show the responsibilities.
“Compare K-means clustering and K-NN algorithms on the basis of learning methodology and applications.” (May 2026)
The short answer
K-means is an unsupervised method that groups unlabelled data into K clusters by repeating assignment and mean update. K-NN is a supervised method that labels a new point by the vote of its K nearest labelled neighbours.
Write these points
K-means steps
Choose K and start with K centres.
Assign every point to its nearest centre.
Move each centre to the mean of its points.
Repeat until the assignments stop changing.
K-NN steps
Keep all labelled training points. There is no training step (lazy learning).
For a new point find the K nearest points by distance.
Give it the majority class (or the average value for regression).
Round 1 groups: first three points and the last four. New centres (1.83, 2.33) and (4.13, 5.38).
Round 2 moves (3,4) to the second group. New centres (1.25, 1.5) and (3.9, 5.1). Round 3 changes nothing, so it stops.
K-NN with K = 3: query (2,2) with labelled points A(1,1) class 0, B(1.5,2) class 0, C(3,4) class 1. Distances 1.41, 0.5, 2.24. Votes 0, 0, 1 give class 0.
Real-life example
K-means is a teacher sorting a pile of unmarked test copies into groups by handwriting. K-NN is a new student asking the 3 nearest neighbours which tuition class they joined and copying the majority.
Figure: K-means and K-NN
Same or opposite: K-means and K-NN
Point
K-means
K-NN
Same or opposite
Learning type
Unsupervised
Supervised
Opposite
Needs labelled data
No
Yes
Opposite
Uses distance between points
Yes
Yes
Same
K means
Number of clusters
Number of neighbours
Opposite
Exam tip. Put the table first, since the question says compare. Show both procedures in short steps. Avoid mixing the two meanings of K.
Q7. Artificial neural network and multilayer perceptron
Asked 1 time in 2026 · Unit 4
From the papers
“Define Artificial Neural Networks and explain the architecture and working principle of multilayer perceptron models in Machine Learning systems” (May 2026)
The short answer
An artificial neural network (ANN) is a model of connected neurons that each pass a weighted sum through an activation function. A multilayer perceptron (MLP) stacks an input layer, hidden layers and an output layer.
Write these points
Architecture of an MLP
Input layer: one unit per feature.
Hidden layers: each unit computes f(w.x + b). The activation f is non linear (ReLU, tanh, sigmoid).
Output layer: softmax or sigmoid for classes, linear for numbers.
Layers are fully connected and signals move forward only (feed forward).
Working principle
Forward pass: compute each layer from the one before.
Loss: compare the output with the target.
Back propagation: use the chain rule to get the gradient of the loss for every weight.
Update: weights move against the gradient (gradient descent).
Repeat over many mini batches (epochs).
One hidden layer with enough units can approximate any smooth function (universal approximation).
Without a non linear activation the whole MLP collapses to one linear model.
Hidden sums 2 x 1 + 0 - 1 = 1 and -2 x 1 - 0 + 3 = 1. Both outputs sigmoid(1) = 0.731.
Output weights (2, 2) and bias -3: sum = 2.924 - 3 = -0.076. Output = sigmoid(-0.076) = 0.481.
Real-life example
A bank form goes through three desks. Desk one copies the entries. Desk two judges income and history. Desk three decides. Wrong results send feedback back through the desks, which is back propagation.
Figure: a forward pass through an MLP
Same or opposite: single perceptron and MLP
Point
Single perceptron
MLP
Same or opposite
Hidden layers
None
One or more
Opposite
Can learn XOR
No
Yes
Opposite
Trained by gradient based updates
Yes
Yes
Same
Decision boundary
Straight line
Curved
Opposite
Exam tip. Draw the layers with arrows. Write the five training steps. Say "non linear activation" clearly, since it is what makes hidden layers useful.
“Explain ReLU activation function and discuss its advantages over sigmoid and tanh activation functions” (May 2026)
The short answer
ReLU (rectified linear unit) is the activation f(z) = max(0, z). Hidden layers use it more than sigmoid or tanh because it trains faster and does not saturate for positive inputs.
Write these points
Advantages of ReLU
No saturation for z > 0: the slope is exactly 1, so gradients do not shrink as they pass back through layers.
Cheap: one comparison, no exponent.
Sparse output: many units give 0, which saves computation and can help generalization.
Faster training: networks with ReLU often converge several times faster than with tanh.
Problems of sigmoid and tanh
Both flatten at large positive and negative z. The slope is near 0 there (the vanishing gradient).
The sigmoid slope is at most 0.25. Its output is not centred on zero.
Both need an exponent, which costs more time.
Weakness of ReLU
A unit with z always below 0 gives 0 and a zero gradient. It stops learning (a dead ReLU).
Fixes: Leaky ReLU (slope 0.01 for z < 0), PReLU, ELU and a smaller learning rate.
Function
Range
Max slope
Dead zone
Sigmoid
0 to 1
0.25
Both ends
tanh
-1 to 1
1
Both ends
ReLU
0 to infinity
1
z < 0
Gradient after 5 layers.
If each sigmoid layer passes a slope of 0.25 (the best case), the gradient is 0.25^5 = 0.00098.
For active ReLU units the slope is 1 each time, so 1^5 = 1. The signal reaches the first layer.
Real-life example
Water passing through a pipe system. With sigmoid each joint leaks three quarters of the flow, so little reaches the last room. With ReLU an open joint passes everything. A closed joint passes nothing.
Figure: sigmoid, tanh and ReLU
Same or opposite: ReLU and sigmoid
Point
ReLU
Sigmoid
Same or opposite
Formula
max(0, z)
1 / (1 + e^-z)
Opposite
Slope for large positive z
1
Near 0
Opposite
Non linear
Yes
Yes
Same
Cost to compute
Very cheap
Needs an exponent
Opposite
Exam tip. Write the formula and plot all three on one set of axes. Give the 0.25^5 versus 1 number. Do not forget to name the dead ReLU weakness.
“Explain various guidelines for conducting Machine Learning experiments and discuss their significance in obtaining reliable results” (May 2026)
The short answer
Guidelines for ML experiments are a plan that makes a comparison of algorithms fair and repeatable. They run from stating the aim to reporting the conclusions with statistics.
Write these points
The steps
Aim of the study: state what you want to know, for example which of two classifiers is better on this data.
Response variable: choose what to measure, such as error rate, precision, recall, training time or memory.
Factors and levels: list what you vary (algorithm, hyperparameters, data set) and the values tried.
Experimental design: use replicated runs on the same data splits for every method. Randomise the order. Keep a separate test set.
Perform the experiment: fix the random seeds, tune all methods with the same effort, save the logs.
Statistical analysis: use a test (paired t test, McNemar) instead of looking at a single number.
Conclusions and recommendations: state what is shown and its limits.
Why they matter
Without a fair design one method may look better by luck or because it was tuned more.
Repeated runs show the spread of the result, not just one lucky score.
Others can repeat the work.
Choosing the number of runs.
Two classifiers are compared with 10 fold cross validation. This gives 10 paired error values per method.
Mean difference 0.018 and standard deviation 0.0103 give a paired t value of 5.5. With 10 runs the test has 9 degrees of freedom.
One single split would have shown only one difference and no way to judge whether it is real.
Remember. The seven step list follows a common textbook scheme (Alpaydin). Other books group the steps a little differently.
Real-life example
Two cricket coaches claim their batter is better. A fair test uses the same pitch, the same bowlers and many innings, then compares averages. One innings on different pitches proves nothing. ML experiments need the same fairness.
Figure: steps of an ML experiment
Same or opposite: a single train and test split and repeated resampling
Point
Single split
Repeated resampling
Same or opposite
Number of scores
One
Many
Opposite
Shows the spread of results
No
Yes
Opposite
Uses held out test data
Yes
Yes
Same
Cost
Low
Higher
Opposite
Exam tip. Write the seven steps as a numbered list with a few words each. Close with the reason: fair, repeatable and statistically checked results.
Q10. Resampling techniques and classification metrics
Asked 1 time in 2026 · Unit 5
From the papers
“Describe resampling techniques and Discuss accuracy, precision, recall and F1-score metrics with suitable examples.” (May 2026)
The short answer
Resampling reuses one data set to make many training and test sets, so we can estimate how a model will do on new data. The usual ones are k fold cross validation, leave one out and the bootstrap.
Write these points
Resampling techniques
Hold out: one split, for example 80 percent train and 20 percent test. Simple but depends on the split.
K fold cross validation: split into k parts. Train on k - 1 parts and test on the left out part. Repeat k times and average. Usual k is 5 or 10.
Leave one out: k equals the number of examples. Almost unbiased but slow.
Bootstrap: draw n examples with replacement. About 63.2 percent of distinct examples appear. The rest (36.8 percent) form a test set.
5 fold CV on 100 examples trains on 80 and tests on 20 each time. The chance an example is left out of a bootstrap sample of 100 is (1 - 1/100)^100 = 0.366.
Real-life example
If a teacher takes just one test, a lucky day can fool her. Taking five small tests and averaging, as k fold does, gives a more honest picture of a student. Precision and recall are like asking how many of the arrests were guilty and how many guilty people were caught.
Figure: 5 fold cross validation
Same or opposite: precision and recall
Point
Precision
Recall
Same or opposite
Counts against it
False positives
False negatives
Opposite
Important when
A false alarm is costly
A miss is costly
Opposite
Both come from TP
Yes
Yes
Same
Combined by
F1
F1
Same
Exam tip. Name the three or four resampling methods with one line each. Draw the confusion matrix and use one set of numbers for all four metrics.
What are the most important topics in Machine Learning for Data Science?
By how often they were asked in the papers on this site: Motivation for machine learning and generalization (1 times); VC dimension and PAC learning (1 times); Supervised learning: architecture and workflow (1 times); Regression, probabilistic classifiers and ensembles compared (1 times); Expectation Maximization (EM) algorithm (1 times).
How were these Machine Learning for Data Science important questions chosen?
Each topic was counted from the questions in the past papers listed on this site (2026). Repeated is the number of times the topic came. The counts come from keyword matching and the answers are not teacher-reviewed, so use them together with your syllabus.
Is there a PDF of Machine Learning for Data Science important questions with answers?
Yes. The Paperwala Imp Question & Answer PDF for Machine Learning for Data Science is free to download from this page.
The 10 most repeated topics of Machine Learning for Data Science (CD-802-D) for RGPV B.Tech CSE-DS semester 8, counted from the previous year papers on this site.