본문으로 바로가기
# Python Deep Dive

Python을 제대로
이해하기

GIL, CPython 내부 동작, 메모리 관리까지.
Python 핵심 개념을 퀴즈로 학습합니다.

deep_copy.py
import copy

a = [[1, 2], [3, 4]]
b = a.copy()        # shallow copy
c = copy.deepcopy(a)  # deep copy

a[0][0] = 999
print(b[0][0])  # ?
print(c[0][0])  # ?

Topics

Python 핵심 주제들을 다룹니다

# Python Internals

GIL (Global Interpreter Lock)

Python 멀티스레딩의 한계와 우회 방법

CPython Internals

레퍼런스 카운팅, 가비지 컬렉션의 동작 원리

Memory Management

객체 생성, 메모리 할당과 해제

# Data Structures

Mutable vs Immutable

list, tuple, set, dict의 차이와 동작 원리

Shallow vs Deep Copy

얕은 복사와 깊은 복사의 차이점

Collections Module

defaultdict, Counter, deque 등 고급 자료구조

# Functions & Control Flow

Generator & Iterator

yield, lazy evaluation, 메모리 효율

Decorator & Closure

함수형 프로그래밍과 메타프로그래밍

Function Arguments

*args, **kwargs, 기본값과 스코프

Exception Handling

try/except/finally, 예외 체이닝

# OOP & Concurrency

Object-Oriented Python

MRO, 다중 상속, 메타클래스

Concurrency

threading, multiprocessing, asyncio