Understanding Python's Object Reference and Mutable Types

View organization page for freeCodeCamp

2,235,522 followers

Python doesn't use traditional call by value or call by reference, which can make function behavior confusing at first. In this tutorial, Mokshita teaches you how passing by object reference works in Python, and how it differs from languages like C. You'll also learn how mutable and immutable types affect what changes inside a function. https://lnkd.in/g5ttBBm7

  • No alternative text description for this image

freeCodeCamp I like how you show mutable vs immutable clearly. It makes function behavior feel less confusing fast.

Like
Reply

Outside function: 15 ← original unchanged There is an error in line above from the explanation above.

See more comments

To view or add a comment, sign in

Explore content categories