Side-by-side, interactive cheatsheets for C# programmers
comparing C# to other languages. Every example runs live in your browser — no
setup, no installation.
Choose your own path by reordering languages
A familiar statically typed language — without the object-oriented ceremony. A C# developer reaches for Go when they want single-binary deployment, goroutines instead of async/await, and errors-as-values instead of exceptions — trading .NET's rich ecosystem for radical simplicity.
Task/async/await, no thread pool; concurrency is baked into the language(result, error) pairs make every failure explicit in the function signature.runtimeconfig.jsonNullReferenceException; every variable is initialized to a safe defaultPython is dynamically typed, interpreted, and indentation-driven — the near-opposite of C# in every technical decision, yet dominant in data science, machine learning, and scripting. The same async/await keywords, the same OOP concepts, but no compiler, no braces, and no type declarations.
name: str) are advisory, not enforced by the runtime[n*n for n in range(10) if n % 2 == 0]) replace LINQ's .Where(...).Select(...).ToList() in one readable expression@dataclass mirrors record: auto-generates constructor, equality, and repr from field annotations; add frozen=True for immutability*args/**kwargs, or isinstance() checks insteadTask/Thread — same async/await keywords, single-threaded event loop, no thread pool; asyncio.gather() is Task.WhenAll()What C# developers reach for when they want expressiveness over ceremony. Ruby drops static, explicit types, and boilerplate for a world where everything is an object, blocks replace delegates, and open classes let you add methods to Integer at runtime.
map, select, reduce, &:upcase replace LINQ's Select/Where/Aggregate without the lambda verbosity42.times, nil.nil?, true.class all work; no primitive/boxing distinctionString, Integer, or any class and add methods at runtime; no extension-method limitationinclude Comparable or Enumerable to gain 50+ methods for free, replacing C# interface boilerplateunless — puts value if valid? reads like plain English; no one-line if (cond) stmt; neededDemanding but deeply rewarding, Rust proves memory safety and bare-metal speed aren't in opposition.
TypeScript is C#'s sibling, not its replacement — same designer (Anders Hejlsberg), same static typing instincts, but running on the JavaScript runtime with structural typing and no runtime type information.
implements declaration — the biggest conceptual shift from C#number type (IEEE 754 float) — no int, long, double, or decimal; use a library for financial arithmeticis MyInterface at runtime; use typeof, instanceof, and discriminant properties insteadnull (explicit absence) and undefined (not set) — always use ===, never ==string | number), literal types ("north" | "south"), and utility types (Partial<T>, Readonly<T>) replace C# enums, DTOs, and separate nullable variantsasync/await over a single event loop — no Task.Run, no threads, no ConfigureAwait(false)C#'s OOP cousin on a different runtime. Java and C# share syntax roots, generics, and a garbage-collected VM — but diverge on checked exceptions, generics implementation, async patterns, and the richness of their standard libraries.
== compares references for objects — always use .equals() for string and object value equality; the most common C# habit that breaks in Javafilter/map/collect) but requires explicit terminal operations and type erasure instead of reified genericsThe English-readable .NET language that pioneered RAD — with static typing, LINQ, and the full .NET ecosystem.
If...Then...End If, For Each...NextAndAlso / OrElse short-circuit logic vs And / OrNothing for nil, Me for self, MyBase for superFunctional-first on the same .NET runtime — without the ceremony of classes. F# starts where C# leaves off: immutability by default, discriminated unions instead of sealed hierarchies, and exhaustive pattern matching enforced by the compiler.
let bindings cannot be reassigned; mutation requires the explicit mutable keyword, making side effects visibletype Shape = Circle of float | Rectangle of float * float and pattern-match exhaustively|> pipe operator threads data through transformations top-to-bottom, replacing LINQ method chains with readable functional pipelinesOption<'T> and Result<'T, 'E> replace null and exceptions for expected failure paths — no NullReferenceException, no hidden throwsGodot's built-in scripting language — Python-flavored, dynamically typed, no compilation step, and designed around Godot's Node tree. C# developers often use GDScript for rapid prototyping and C# for performance-critical systems within the same Godot project.
var x = 42 is a Variant; opt-in type annotations with var x: int = 42match replaces switch — matches ranges, arrays, dicts, and bind-patterns; far more powerful than C# switchsignal health_changed(new_health) is the observer pattern baked into the engine; no delegates requiredvar double = func(x): return x * 2 is explicit; invoke with double.call(5) rather than direct application:= for typed inference — var count := 42 infers int; without := the variable is untyped Variant