"두 언어. 한 정신. 한 codebase."
형제 quest
이 Quest 가 쌍의 frontend 반쪽으로 설계. Python Quest 가 backend 반쪽. 같은 모양 (17 트랙, ~93 lesson), 같은 목표 (cwkPippa source-reader 되기), 같은 voice. 각각 독립적으로 walk 가능; 쌍이 lingua franca duo.
직접 translate 되는 것
- List comprehension ↔ array map/filter. Python 의
[x*2 for x in arr if x > 0]가 TS 의arr.filter(x => x > 0).map(x => x*2). 같은 연산, 다른 문법. - Type hint ↔ TS annotation. Python 의
def f(x: int) -> str가function f(x: number): string. 의미 다름 (Python 의 게 runtime 에 advisory; TS 의 게 compile 시점 체크), 근데 문법 의도 같음. - Protocol ↔ structural typing. Python 의 `typing.Protocol` 이 명시 만든 duck typing, TypeScript 의 structural matching 처럼.
- Discriminated union ↔ tagged union. 같은 패턴. Python 이 Literal 타입 + isinstance / match 씀; TypeScript 가 literal 타입 + typeof / switch 씀.
- async/await. 동일 문법, 살짝 다른 의미 (Python 의 event loop 가 명시, JS 의 게 암묵).
Translate 안 되는 것
- Python 이 metaclass 가짐; TypeScript 안 가짐 (TC39 decorator 가 가장 가까운 analog).
- TypeScript 가 default 로 structural typing 가짐; Python 이 Protocol opt-in 과 nominal-leaning.
- Python 이 GIL-bound concurrency; JavaScript 가 single-threaded event loop.
- TypeScript 가 mapped 타입, conditional 타입, template literal 타입 가짐; Python 의 type system 이 type-computation 레벨에 더 제한적.
두 언어가 mirror 된 어휘로 같은 문제 공간 cover. 두 quest 다 walk 하면 codebase 의 두 반쪽 가로질러 한 정신 carry. cwkPippa 가 증거.