Start Learning
Javaneer
Back to roadmap
✍️
Stage 1

Syntax for Java Eyes

The same ideas, spelled more concisely.

Kotlin's everyday syntax, taught by contrast with the Java you'd write for the same thing: val over final, type inference, functions with default and named arguments, if/when/try as expressions that return values, string templates, unified number types, ranges, and Kotlin's take on packages, visibility, and exceptions.

6 Lessons in this stage1 h 17 min
Start the first lesson

Lessons in this stage

  1. 01

    val, var & Type Inference

    Beginner

    Declaring variables: val (immutable, like final) vs var, and type inference that drops the ceremony without losing static typing - immutability as the default habit.

    12 min
  2. 02

    Functions, Defaults & Named Args

    Intermediate

    The fun keyword, expression-body functions, and the two features that kill overloads and builders: default parameter values and named arguments at the call site.

    14 min
  3. 03

    Everything Is an Expression

    Intermediate

    if, when, and try return values in Kotlin, so there's no ternary operator and no temporary-then-assign dance - and when is a far more powerful switch.

    14 min
  4. 04

    Strings & Basic Types

    Beginner

    String templates instead of concatenation, triple-quoted raw strings, and a type system with no primitives - Int, Long, Double are real types, unified but compiled efficiently.

    12 min
  5. 05

    Control Flow & Ranges

    Beginner

    for over ranges and collections, ranges as first-class values (1..10, until, downTo, step), and why Kotlin drops the C-style for loop for something more readable.

    12 min
  6. 06

    Packages, Visibility & Exceptions

    Intermediate

    Package and import rules, visibility modifiers (public by default, plus internal), top-level declarations - and the big one for Java devs: Kotlin has no checked exceptions.

    13 min