← Back to videos

Mock interview for a Junior Python Developer – Muhammad

Interview timeline Click any block to jump

Interview breakdown

Interviewer verdict
Needs more practice Level: Intern / Beginner (rote FAQ answers without deep understanding)

Current depth is not yet sufficient for a Junior role: the candidate handles textbook FAQ prompts (mutable vs immutable types), but once questions probe real understanding he contradicts himself, struggles with 'is' vs '==', list indexing vs hashing, and cannot explain built-in isinstance(True, int).

Candidate: Muhammad
Target role: Junior Python Developer

~2 years learning Python · Yandex Practicum graduate, currently interning at Intouch and working on personal pet projects

Answers accuracy 13 total
35% score
Theory
2/10 correct · 40%
Live coding
0/3 correct · 17%
Practical task
Not solved

Type checking: isinstance(True, int/bool) vs type(True) == int/bool

Unfamiliar with built-in isinstance(), the candidate initially guessed it checks whether arguments are non-empty, predicted False for isinstance(True, int), and after seeing True argued that 'True contains an int inside' rather than recognizing that bool is a subclass of int.

Topics covered Click a topic to filter questions

Candidate strengths

  • + Knows the standard classification of built-in mutable and immutable Python types (including frozenset)
  • + Stayed engaged and communicative throughout his first live technical interview despite nerves
  • + Receptive and constructive attitude toward detailed feedback on foundational gaps

Areas to improve

  • → State 'I don't know, here is my hypothesis' openly instead of bluffing through contradictions and digging deeper
  • → Rebuild core object-model fundamentals: classes vs instances, NoneType singleton, and '==' vs 'is'
  • → Learn type inheritance (bool subclasses int) and why isinstance() differs from exact type(x) == ... checks
  • → Understand O(1) array indexing in Python lists vs key-based O(1) lookup in hash tables (dict/set)

Questions in this interview

13 / 13
01 ▶ 03:27
What data types exist in Python, and how do mutable types differ from immutable ones?
Theory Data types, numbers & memory
?
Candidate's answer

Cleanly categorized immutable types (tuple, int, bool, str, frozenset) vs mutable ones (list, dict, set), noting in-place mutability and hashability.

Key takeaway

Mutable objects change state in-place keeping the same id(), while immutable objects allocate new instances on change and (when recursively immutable) are hashable.

Open moment on YouTube ↗
#01
02 ▶ 04:50
What are a data type and an object in Python, and how are objects created?
Theory OOP, classes & dunder methods
?
Candidate's answer

Initially stated correctly that types define object structure in memory and objects are created from classes, before losing conviction on follow-up questions.

Key takeaway

In Python 3, 'type' and 'class' are unified: every runtime value (int, str, list, function) is an object instantiated from its corresponding class.

Open moment on YouTube ↗
#02
03 ▶ 10:54
Can Python objects exist without classes — e.g., created from functions or variable literals — and how do they differ?
Theory OOP, classes & dunder methods
?
Candidate's answer

Started improvising contradictions: claimed class-created objects are mutable lists while function-created objects are immutable tuples, and attributed built-in runtime types to the typing module.

Key takeaway

Every Python object has a class: literals like 42 or [1] instantiate built-in int and list classes, while the 'typing' module is purely for static type hints.

Open moment on YouTube ↗
#03
04 ▶ 14:28
How do you inspect the type of an object in Python?
Theory Data types, numbers & memory
?
Candidate's answer

Correctly named built-in type(obj) and noted that passing a function returns a function class.

Key takeaway

Calling type(obj) with one argument returns obj.__class__, the exact class the object was instantiated from.

Open moment on YouTube ↗
#04
05 ▶ 15:22
Are iterability and mutability the same property in Python?
Theory Decorators, iterators, generators & context managers
?
Candidate's answer

First misspoke that tuples aren't iterable, then corrected himself citing __iter__/__next__ on immutable tuples, before contradicting himself again.

Key takeaway

Iterability and mutability are independent: str and tuple are immutable yet iterable, int is neither, and list/dict/set are both mutable and iterable.

Open moment on YouTube ↗
#05
06 ▶ 17:53
How do you check an object's type in a conditional branch in Python?
Theory Data types, numbers & memory
?
Candidate's answer

Proposed 'if type(x) == int:', saying he couldn't recall any other standard way to check types.

Key takeaway

Idiomatic Python uses isinstance(x, int) (or a tuple of types) so subclasses match properly, reserving type(x) is int for rare exact-class checks.

Open moment on YouTube ↗
#06
07 ▶ 20:29
What is None in Python, and does it have a data type?
Theory Data types, numbers & memory
?
Candidate's answer

Described None as representing the absence of a value, but mistakenly concluded that None is not a data type / has no type.

Key takeaway

None is the sole singleton instance of the built-in class NoneType (type(None) is types.NoneType).

Open moment on YouTube ↗
#07
08 ▶ 21:53
What does the 'is' operator check, and how does it differ from '=='?
Theory Data types, numbers & memory
?
Candidate's answer

Generalized from 'if data is not None' to claim 'is' checks whether an object exists or holds data, eventually admitting he couldn't explain how 'is' differs from '=='.

Key takeaway

'==' tests value equality via __eq__(), whereas 'is' tests object identity in memory (id(a) == id(b)) — which is why singletons like None are checked with 'is None'.

Open moment on YouTube ↗
#08
09 ▶ 26:06
What is an object hash, and what problem does hashing solve in Python?
Theory Collections, lists, dicts & hash tables
?
Candidate's answer

Gave a good warehouse-navigation analogy for fast lookup without scanning everything, but inaccurately defined a hash as a 'hashed memory-cell index'.

Key takeaway

A hash is a deterministic integer computed from an immutable object's value via __hash__() to map keys directly to hash-table buckets in dict and set in O(1) average time.

Open moment on YouTube ↗
#09
10 ▶ 29:29
How does hash-based lookup differ from numeric index access in a Python list (list[i])?
Theory Collections, lists, dicts & hash tables
?
Candidate's answer

Confused O(n) mid-list insertion shifts with index lookup, claimed tuples lack indices, and concluded reading lst[3] requires iterating from index 0 to 3.

Key takeaway

List and tuple indexing seq[i] jumps directly via pointer offset in O(1) without scanning; hash tables enable O(1) lookup by arbitrary keys (e.g., strings) and O(1) membership tests.

Open moment on YouTube ↗
#10
11 ▶ 35:07
What is the purpose of built-in isinstance(obj, classinfo), and what arguments does it take?
Live coding OOP, classes & dunder methods
?
Candidate's answer

Admitted never using isinstance() himself and initially guessed it checks whether any non-empty argument was passed before eventually arriving at type checking with heavy prompting.

Key takeaway

isinstance(obj, cls) takes an object and a class (or tuple/union of classes) and returns True if obj is an instance of cls or any subclass thereof.

Open moment on YouTube ↗
#11
12 ▶ 44:11
What do isinstance(True, int), isinstance(True, bool), type(True) == int, and type(True) == bool print?
Live coding OOP, classes & dunder methods
?
Candidate's answer

Predicted False, True, False, True — getting the last three right but missing that isinstance(True, int) evaluates to True.

Key takeaway

The output is True, True, False, True: True's exact class is bool (so type(True) == int is False), while bool subclasses int (so isinstance(True, int) is True).

Open moment on YouTube ↗
#12
13 ▶ 46:38
Why does isinstance(True, int) return True while type(True) == int returns False?
Live coding OOP, classes & dunder methods
?
Candidate's answer

Tried explaining that 'True contains an int (1 and 0) inside under the hood', missing class inheritance and MRO.

Key takeaway

In Python (PEP 285), bool is a subclass of int (issubclass(bool, int) is True). isinstance() walks the inheritance hierarchy, whereas type(x) == cls checks only the exact class.

Open moment on YouTube ↗
#13
Original video description & timecodes

This video features a mock interview for the role of Junior Python Developer. The candidate discusses their career path in development, as well as their training and internship experience, after which the interview moves on to basic yet highly revealing questions about Python: data types, mutable and immutable objects, hashing, type comparison, and the differences between `type`, `is` and `isinstance`.

The conversation proved particularly useful because, rather than relying on memorised, formulaic questions, it specifically tests the candidate’s understanding. Using simple examples, it is clear to see how the candidate reasons, where they get confused with terminology, begin to contradict themselves, and where exactly their foundational knowledge lacks depth. A separate section is devoted to code review and why checks in Python that appear identical at first glance can yield different results.

This video will be useful for those preparing for their first Python developer interview, wanting to understand the typical mistakes made by junior candidates, and wishing to learn not just to memorise answers, but to truly grasp the fundamentals of the language.

Timecodes

00:00 Introduction and interview plan
00:30 Introducing the participants
03:24 Theoretical questions
35:02 Working with code
53:12 Feedback session

Hashtags

#python #juniorpython #interview #it #programming #pythondeveloper #oop #interview