PONY λ M2 Modula-2
for Perl programmers

You already know Perl.Now explore other languages.

Side-by-side, interactive cheatsheets for Perl programmers
comparing Perl to other languages. Every example runs live in your browser — no setup, no installation.

▶ Start with JavaScript Browse comparisons ↓

Choose your own path by reordering languages

JavaScript Alpha ⚡ Works Offline ⚡ Offline

What Perl programmers get when sigils disappear and a Promise takes over waiting. JavaScript keeps Perl's first-class regex literals and no-compile-step feel, but drops $/@/% sigils for one bare name per variable, replaces manual bless-based objects with a native class keyword, and adds a built-in async/await concurrency model Perl has no equivalent for at all.

  • No sigils — one bare name for every variable, whether it holds a scalar, an array, or an object, with no $item-inside-an-@array inconsistency
  • No context sensitivity — an expression always evaluates to exactly one thing; there is no scalar-vs-list surprise and no wantarray to reason about
  • A native class keyword with constructor() and #private fields, replacing hand-written bless-and-assign boilerplate and Perl's underscore-convention-only privacy
  • Destructuring and template literals — const { name, age } = person and `Hello, ${name}` replace Perl's hash-slice syntax and the @{[ expression ]} interpolation trick
  • Promise and async/await — a genuine language-level concurrency primitive with no Perl core equivalent, which otherwise needs a CPAN event-loop module and manual callbacks
  • npm and package-lock.json in place of CPAN and Carton's cpanfile.snapshot, with reproducible installs generated automatically rather than through a separate opt-in tool
Python Beta ⚡ Works Offline ⚡ Offline

Perl's own favorite child for scripting and the web, Python keeps the quick-iteration, no-compile-step feel you know, but trades sigils and context sensitivity for one plain name per variable and a single, predictable meaning for every expression.

  • No sigils — $scalar, @array, and %hash all collapse into one bare, unpunctuated name
  • No context sensitivity — an expression always means the same thing, so no scalar-vs-list surprises
  • List, dict, and set comprehensions replace map/grep chains with one readable left-to-right expression
  • A native class keyword and real inheritance instead of manually bless-ing a hash reference
  • Named parameters and real keyword arguments instead of manually unpacking @_
  • pip and PyPI in place of cpanm and CPAN, with a batteries-included standard library covering more everyday needs
Java Pre-Alpha

The mandatory, fully-featured native OOP system Perl programmers have to hand-roll. Java trades Perl's sigils, context sensitivity, and bless-based objects for compiler-enforced static types, real encapsulation and generics, low-ceremony records, and a checked-exception contract Perl has no equivalent for.

  • Real static typing catches errors at compile time — no more discovering a type mistake only when that code path finally runs
  • A mandatory but genuinely strong native class system: real encapsulation, interfaces, and generics in place of package + hand-written bless
  • Records (Java 16+) — a low-ceremony immutable data class, the closest Java equivalent to a lightweight Perl hash-based struct
  • Checked exceptions force every caller to handle or declare a failure — the explicit error contract Perl's unconstrained die never offers
  • A vast enterprise ecosystem via Maven Central, plus strong IDE tooling that static types make possible
  • No sigils, no context sensitivity — one bare name per variable, and an expression always means the same thing regardless of where it appears
PHP Pre-Alpha ⚡ Works Offline ⚡ Offline

What Perl programmers get when sigils collapse to one and objects stop needing bless. PHP keeps Perl's PCRE-descended regex engine and pragmatic web-scripting roots, but drops $/@/% sigils for one $ prefix, separate array and hash types for a single ordered-map array, and manual bless-based objects for a native class keyword with constructor property promotion.

  • A real class keyword with constructor property promotion — public readonly string $name in the constructor signature replaces Perl's hand-written bless-and-assign boilerplate
  • One array type does double duty — no reference gymnastics to nest a hash inside an array the way Perl needs an array-of-hash-refs; a PHP array is just an array, indexed or associative or both
  • Named arguments and default parameters built into every function signature — no more unpacking @_ into a hash to simulate Perl-style keyword arguments
  • Composer autoloading resolves class names to files automatically — no use lib path-juggling before requiring a dependency
  • No context sensitivity anywhere — an expression always evaluates to exactly one thing; there is no scalar-vs-list surprise and no wantarray to reason about
Ruby ⚡ Works Offline ⚡ Offline

What Perl programmers get when the sigils and context sensitivity disappear. Ruby kept Perl's regex literals, postfix conditionals, and pragmatic soul, but dropped $/@/% sigils, scalar-vs-list context, and manual bless-based objects for a single uniform object model and a real class keyword.

  • No sigils — one bare name for every variable, whether it holds a scalar, an array, or a hash, with no $item-inside-an-@array inconsistency
  • No context sensitivity — an expression always evaluates to exactly one thing; there is no scalar-vs-list surprise and no wantarray to reason about
  • A real class keyword — attr_accessor, initialize, and < for inheritance replace hand-written bless, manual accessors, and @ISA
  • Blocks as language syntax — array.each { |item| ... } replaces Perl's explicit anonymous-sub-and-arrow-call ceremony for passing behavior around
  • Rails — the framework that popularized convention-over-configuration and shaped how a generation of web frameworks, including modern Perl ones, are built
Drag cards to reorder · your order is saved locally