Phone Number: +91 72599 12345
Career Guidance

Top 20 Data Science Interview Questions and Answers for Freshers (2026)

Data science interview questions by round - Python, statistics, machine learning, deep learning, Generative AI and project discussion - with concise answers.

Data science interviews for freshers in Bangalore usually have three parts: a screening on Python and statistics, a technical round on machine learning and a case or project discussion where you explain work you have done. Recruiters at IT services companies, startups and analytics teams increasingly add Generative AI questions as well. The questions below are the ones our learners report most often, grouped by round, with short answers you should be able to expand on with examples from your own projects.

Python and data handling

1. How do you handle missing values in a dataset?

First understand why they are missing. Options: drop rows or columns if the proportion is small and random, impute with mean/median/mode or a model-based method, or add a missing indicator. In pandas: df.isna().sum(), fillna(), dropna().

2. What is the difference between a list, a tuple and a dictionary, and when would you use NumPy arrays?

Lists are mutable sequences, tuples immutable, dictionaries key-value maps. NumPy arrays are fixed-type, vectorised and far faster for numerical work, which is why pandas is built on them.

3. How do you merge two DataFrames and what join types exist?

pd.merge(left, right, on=key, how='inner'|'left'|'right'|'outer'). Explain when a left join is needed to keep all records from the primary table.

4. Write a SQL query to find the second-highest salary.

Use a window function: SELECT salary FROM (SELECT salary, DENSE_RANK() OVER (ORDER BY salary DESC) r FROM employees) t WHERE r = 2; Interviewers often ask SQL even for data science roles.

Statistics

5. Explain the difference between mean, median and mode and when the median is preferred.

The median is robust to outliers, so it is preferred for skewed data such as salaries or house prices.

6. What is a p-value?

The probability of observing data at least as extreme as what you saw if the null hypothesis were true. A small p-value is evidence against the null, but it is not the probability that the null is true.

7. What is the Central Limit Theorem and why does it matter?

The distribution of sample means approaches normal as sample size grows, regardless of the population distribution, which justifies confidence intervals and many hypothesis tests.

8. Correlation versus causation?

Correlation measures association; causation requires controlled experiments or causal inference methods. Give a confounder example.

Machine learning

9. Explain the bias-variance trade-off.

High bias means the model is too simple and underfits; high variance means it fits noise and overfits. Regularisation, more data, cross-validation and ensembles manage the balance.

10. How do you choose evaluation metrics for a classification problem?

Accuracy fails on imbalanced data. Use precision when false positives are costly, recall when false negatives are costly, F1 to balance them, and ROC-AUC or PR-AUC to compare models across thresholds.

11. What is the difference between bagging and boosting?

Bagging (random forest) trains models in parallel on bootstrap samples and averages them to reduce variance. Boosting (XGBoost, LightGBM) trains sequentially, each model correcting the previous errors, to reduce bias.

12. How do you handle class imbalance?

Resampling (SMOTE, undersampling), class weights, threshold tuning, and choosing the right metric. Explain which you used in a project and why.

13. What is cross-validation and what is data leakage?

K-fold cross-validation estimates generalisation by rotating validation folds. Leakage happens when information from the validation or future data enters training, for example scaling before splitting, and produces misleadingly good results.

14. Explain regularisation: L1 versus L2.

L1 (Lasso) adds the absolute value of coefficients and can zero them out (feature selection); L2 (Ridge) adds squared coefficients and shrinks them smoothly.

15. When would you use K-Means, and how do you choose K?

For partitioning numeric data into spherical clusters. Choose K with the elbow method or silhouette score, and scale features first.

Deep learning, NLP and Generative AI

16. What is the difference between a CNN and an RNN/LSTM?

CNNs use convolutions to learn spatial patterns, suited to images; RNNs and LSTMs process sequences with memory, suited to time series and text, though transformers have largely replaced them in NLP.

17. How does a transformer differ from earlier NLP models, and what is an embedding?

Transformers use self-attention to weigh all tokens in a sequence at once, enabling parallel training and long-range context. An embedding is a dense vector representing a word, sentence or document so that similar meanings are close in vector space.

18. What is Retrieval-Augmented Generation (RAG)?

RAG retrieves relevant documents from a vector database using embeddings and passes them to an LLM as context, reducing hallucination and letting the model answer from private data. Mention chunking, embedding models and evaluation.

19. How do you prevent overfitting in a neural network?

Dropout, early stopping, data augmentation, weight decay, batch normalisation and simply more data.

Project and case discussion

20. Walk me through a project end to end.

Problem framing and success metric, data collection and cleaning, EDA findings, feature engineering, model choice and why, evaluation with the right metric, what you deployed or would deploy, and what you would do differently. Have one project where you can answer every follow-up.

Preparation tips

  • Pick two or three portfolio projects (for example a recommendation system, a fraud-detection model and a RAG chatbot) and know every design decision in them.
  • Practise explaining metrics to a non-technical person; case rounds test communication.
  • Revise SQL; it is asked in most data roles.
  • Know the market: entry-level data science roles in Bangalore are reported around ₹4–8 LPA, rising to ₹12–22 LPA with experience (Glassdoor and Naukri).

The Data Science course in Bangalore at MNP Technologies covers Python, statistics, machine learning, deep learning, NLP, Generative AI and deployment through industry projects and includes mock interviews based on questions like these.