Python Engineer Interview Questions

6,383 python engineer interview questions shared by candidates

Python Basics: List vs. tuple vs. set vs. dictionary – differences and use cases. Mutable vs. immutable objects with examples. How does garbage collection work in Python? Explain *args and **kwargs. What are decorators? Write an example. How do __init__ and __new__ differ? What are Python generators? Yield vs. return. OOP & Design Patterns: Explain inheritance, polymorphism, and encapsulation. What is method overriding vs. method overloading? What’s a metaclass? When would you use it? Singleton pattern – how to implement it in Python? Algorithms & Data Structures: Reverse a string/list in place. Find duplicates in a list/array. Check if two strings are anagrams. Explain time complexity (Big-O) of common operations. Frameworks & Libraries: Django vs. Flask – key differences. How do Django models work with databases? What is middleware in Django/Flask? Async vs. sync code – when to use each? Databases: SQL vs. NoSQL – pros and cons. How to optimize a slow SQL query? What are indexes, and when should you use them? Experience with ORMs (Django ORM, SQLAlchemy). Testing & Debugging: How do you write unit tests? (unittest/pytest) What’s mocking, and why is it useful? How would you debug a memory leak? System Design: Design a REST API for a blog. How would you handle high traffic on an API? Explain caching strategies (Redis, Memcached). DevOps & Tools: Git workflow – branching, merging, rebasing. What’s CI/CD? How have you used it? Docker basics – what’s a container vs. an image?
avatar

Python Developer

Interviewed at DataArt

4.5
Jul 29, 2025

Python Basics: List vs. tuple vs. set vs. dictionary – differences and use cases. Mutable vs. immutable objects with examples. How does garbage collection work in Python? Explain *args and **kwargs. What are decorators? Write an example. How do __init__ and __new__ differ? What are Python generators? Yield vs. return. OOP & Design Patterns: Explain inheritance, polymorphism, and encapsulation. What is method overriding vs. method overloading? What’s a metaclass? When would you use it? Singleton pattern – how to implement it in Python? Algorithms & Data Structures: Reverse a string/list in place. Find duplicates in a list/array. Check if two strings are anagrams. Explain time complexity (Big-O) of common operations. Frameworks & Libraries: Django vs. Flask – key differences. How do Django models work with databases? What is middleware in Django/Flask? Async vs. sync code – when to use each? Databases: SQL vs. NoSQL – pros and cons. How to optimize a slow SQL query? What are indexes, and when should you use them? Experience with ORMs (Django ORM, SQLAlchemy). Testing & Debugging: How do you write unit tests? (unittest/pytest) What’s mocking, and why is it useful? How would you debug a memory leak? System Design: Design a REST API for a blog. How would you handle high traffic on an API? Explain caching strategies (Redis, Memcached). DevOps & Tools: Git workflow – branching, merging, rebasing. What’s CI/CD? How have you used it? Docker basics – what’s a container vs. an image?

In L1->4 sum array question arr=[2,4,3,5,6,1,0] target=10 something like this. In L2-> asked to right a user auth api and use it in the endpoint (i used Depends from fastAPI) and another coding question was about parenthesis match is_valid_parenthesis([({})]) #TRUE. React question- useLayoutEffect vs useEffect, useMemo, useCallback. js- output based js question related to event loop priority like promise vs setTimeout vs console.log use chatGPT it will give you the exact question. GenAi- which model i have used like GPT-4o similar like this try to read about the Transformer how it works. sql- A 1 1 1 1 1 B 1 1 1 1 what will be the inner join left join right join and full outer join. you need to be prepared i lost my chance. Please don't do the same. Try to explain the code you write.
avatar

Python Full Stack Developer

Interviewed at UST

3.8
Jun 3, 2025

In L1->4 sum array question arr=[2,4,3,5,6,1,0] target=10 something like this. In L2-> asked to right a user auth api and use it in the endpoint (i used Depends from fastAPI) and another coding question was about parenthesis match is_valid_parenthesis([({})]) #TRUE. React question- useLayoutEffect vs useEffect, useMemo, useCallback. js- output based js question related to event loop priority like promise vs setTimeout vs console.log use chatGPT it will give you the exact question. GenAi- which model i have used like GPT-4o similar like this try to read about the Transformer how it works. sql- A 1 1 1 1 1 B 1 1 1 1 what will be the inner join left join right join and full outer join. you need to be prepared i lost my chance. Please don't do the same. Try to explain the code you write.

1. how memory management is works in python. 2. What data structured you have used , what is dictionary and how it works behind the scenes. why key value pair ? 3. If you have 2 technology Node and Python, what you will choose and why ? 4. What is event loop in js/node js, how it works ? 5. what Idempotency in a REST API 6. If you will develope REST API in Django what things you will consider ?
avatar

Senior Python Developer

Interviewed at Persistent Systems

4.2
Jan 10, 2025

1. how memory management is works in python. 2. What data structured you have used , what is dictionary and how it works behind the scenes. why key value pair ? 3. If you have 2 technology Node and Python, what you will choose and why ? 4. What is event loop in js/node js, how it works ? 5. what Idempotency in a REST API 6. If you will develope REST API in Django what things you will consider ?

Viewing 6351 - 6360 interview questions

Glassdoor has 6,383 interview questions and reports from Python engineer interviews. Prepare for your interview. Get hired. Love your job.