Side-by-side, interactive cheatsheets for Python programmers
comparing Python to other languages. Every example runs live in your browser — no
setup, no installation.
Choose your own path by reordering languages
Python's favorite upgrade path. When you've hit a performance wall or need concurrency without the GIL, Go delivers static types, native goroutines, and 10× throughput — with a learning curve much shorter than Rust or C++.
threading and asyncio with one unified modelThe language of the browser, JavaScript is the one runtime every Python web developer eventually meets on the front end.
[] and {} are truthy in JavaScript but falsy in Pythonnull and undefined — where Python has only None=== vs. ==: the strict equality you should reach for, and the coercing one you should avoidmap, filter, reduce) in place of list comprehensionsthis instead of an explicit selfasync/await with no explicit asyncio.run()Python's closest peer and philosophical foil. Both are readable, dynamic, and expressive, but Ruby's blocks, open classes, and "there's more than one way" ethos give you a richer object model — the language that gave the world Rails and proved convention-over-configuration could be beautiful.
do…end syntax; more powerful than Python's single-expression lambdasnil all have methods; there's no primitive/object split:name vs "name" — a distinction Python's str type doesn't makePython's expressiveness, but with memory safety, concurrency without the GIL, and performance without a rewrite. Rust eliminates entire classes of bugs at compile time while keeping code readable.
Option and Result make None and errors explicit in the type system — no more AttributeError: 'NoneType' object has no attribute at runtimematch — more powerful than Python's match, and the compiler enforces you handle every casePython's familiar syntax meets compile-time type safety. TypeScript catches whole classes of bugs before they run — the same errors that only surface at runtime in Python.
Optional-equivalent T | null — the same expressiveness as Python's type hints, but verified by the compilerinterface and structural typing — like Python's Protocol, but built into the language and checked everywhere<T> — the same concept as Python's TypeVar, with cleaner syntax and broader tooling support`Hello, ${name}!` vs f"Hello, {name}!"Python syntax you already know, plus the performance you've always wanted. Mojo extends Python's familiar syntax with strict typing, value semantics, and SIMD — letting you write Python-style code that compiles to metal.
def functions work exactly like Python's — mutable arguments, implicit typing, no ceremonyfn functions are strict and typed — declared argument mutability, explicit return types, zero runtime overheadvar declares a new variable; Mojo's type inference means you rarely need to spell the type outstruct types have value semantics — no garbage collector, no hidden allocations, fully predictable performancePython.import_module() — call any Python library directlyThe scientific language that compiles to fast machine code, Julia gives Python developers NumPy-style array math and C-like speed without leaving a high-level, dynamic language.
1:3 is 1, 2, 3)sqrt.(values), numbers .* 2) instead of NumPy or loops^ for exponentiation, and div(a, b) for floor divisionend rather than indentationBool — no truthy/falsy valuesWhere Python's data-science world meets the language built by statisticians. R is vector-first and data-frame-native — much of what NumPy and pandas add to Python is simply how R already works.
42 is a length-1 vector and arithmetic is vectorised by default, so loops and comprehensions are rarely neededx[1] is the first element and 1:5 is 1, 2, 3, 4, 5<- for assignment and c() to build vectors, instead of = and list literalsdata.frame is part of base R — the original inspiration for pandas, available with no importNA for missing values, separate from NULL — first-class missingness rather than NaN/Noneapply family (sapply, lapply, vapply) in place of loops and method chains