Learn to code in small bites

Short lessons, then Go exercises you run and check right in your browser. Nothing to install.

Start learning Go

Illustration of a biscuit with one bite taken out, on an orange field; its crumbs are small squares
main.go
package main

import "fmt"

func main() {
	biscuit := 4
	for biscuit > 1 {
		biscuit--
		fmt.Println(biscuit, "left")
	}
}
Output
3 left
2 left
1 left

How learning works

  1. Read a little

    Each lesson covers one small idea, with example code you can try straight away.

  2. Write the code

    Starter code is waiting in the editor. Finish it by following the task at the end.

  3. Run, then Submit

    Run shows the output. Submit checks your code right in the browser, with no server.

  4. One more bite

    The lesson is done and your progress grows. Start the next one whenever you are ready.

5 lesson types across Nibble's courses

  • 99 lessonsTest exerciseHidden tests check your code.
  • 16 lessonsOutput exerciseYour program's output must match exactly.
  • 27 lessonsQuizMultiple choice to close each chapter.
  • 8 lessonsCode exampleReady-to-run code to try and change.
  • 1 lessonReadingJust the text, then mark it done.

The Go course 17 chapters, 97 lessons

The Go gopher, mascot of the Go language, speaking through a megaphone (pencil drawing)

A small, fast language for backends, tools and network services. From variables to generics, then two small projects.

Choose a chapter

Lessons in Variables

  1. Hello, Gopher!Output exercise
  2. Declaring VariablesOutput exercise
  3. Short Variable Declaration :=Test exercise
  4. Basic Data TypesCode example
  5. Quiz: VariablesQuiz

Lessons in Constants and Formatting

  1. ConstantsTest exercise
  2. Constant Blocks and Untyped ConstantsCode example
  3. Formatting Output with fmt.PrintfOutput exercise
  4. Building Strings with fmt.SprintfTest exercise
  5. Column Width and PaddingTest exercise
  6. Quiz: Constants and FormattingQuiz

Lessons in Conditionals

  1. Branching with if and elseTest exercise
  2. Logical OperatorsTest exercise
  3. if with an Init StatementTest exercise
  4. switchTest exercise
  5. Tagless switch and fallthroughTest exercise
  6. Quiz: ConditionalsQuiz

Lessons in Functions

  1. Parameters and Return ValuesTest exercise
  2. Multiple Return ValuesTest exercise
  3. Early Returns and Guard ClausesTest exercise
  4. Functions as ValuesTest exercise
  5. deferOutput exercise
  6. Quiz: FunctionsQuiz

Lessons in Structs

  1. Defining StructsTest exercise
  2. Nested StructsTest exercise
  3. Anonymous StructsCode example
  4. Embedded StructsTest exercise
  5. Methods on StructsTest exercise
  6. Quiz: StructsQuiz

Lessons in Interfaces

  1. Getting to Know InterfacesTest exercise
  2. Satisfying Several InterfacesTest exercise
  3. Type AssertionsTest exercise
  4. Type Switches and anyTest exercise
  5. The Stringer InterfaceOutput exercise
  6. Quiz: InterfacesQuiz

Lessons in Errors

  1. The error InterfaceTest exercise
  2. fmt.Errorf and Wrapping ErrorsTest exercise
  3. Custom Error TypesTest exercise
  4. Panic vs ErrorCode example
  5. Quiz: ErrorsQuiz

Lessons in Loops

  1. The for LoopTest exercise
  2. for as whileTest exercise
  3. Infinite Loops, break, and continueTest exercise
  4. range over IntegersOutput exercise
  5. Looping over Strings and RunesTest exercise
  6. Quiz: LoopsQuiz

Lessons in Slices

  1. Arrays and SlicesTest exercise
  2. make, len, cap, and appendTest exercise
  3. Slicing: Cutting a SliceTest exercise
  4. Variadic Functions and the ... OperatorTest exercise
  5. 2D Slices and the slices PackageTest exercise
  6. Quiz: SlicesQuiz

Lessons in Maps

  1. Getting to Know MapsTest exercise
  2. Checking Whether a Key Exists: Comma-okTest exercise
  3. Iterating over Maps and Key OrderOutput exercise
  4. Counting FrequenciesTest exercise
  5. Nested Maps and Maps of StructsTest exercise
  6. Quiz: MapsQuiz

Lessons in Pointers

  1. Address and Dereference: & and *Test exercise
  2. Pass by Value vs Pass by PointerOutput exercise
  3. Pointer Receivers vs Value ReceiversTest exercise
  4. Nil PointersTest exercise
  5. When Should You Use Pointers?Code example
  6. Quiz: PointersQuiz

Lessons in Packages and Modules

  1. Packages and ImportsCode example
  2. Exported vs UnexportedTest exercise
  3. Modules and the go CommandReading
  4. Standard Library: strings and strconvTest exercise
  5. Standard Library: math and sortTest exercise
  6. Quiz: Packages and ModulesQuiz

Lessons in Channels

  1. Goroutines and ChannelsTest exercise
  2. Buffered ChannelsTest exercise
  3. Close, Range, and Channel DirectionTest exercise
  4. SelectTest exercise
  5. WaitGroup and DeadlockTest exercise
  6. Quiz: ChannelsQuiz

Lessons in Mutexes

  1. Race ConditionsCode example
  2. sync.Mutex: Lock and UnlockTest exercise
  3. Protecting Structs with a MutexTest exercise
  4. sync.RWMutex: Many Readers, One WriterTest exercise
  5. sync.Once and Choosing Between a Mutex and a ChannelTest exercise
  6. Quiz: MutexesQuiz

Lessons in Generics

  1. Generic FunctionsTest exercise
  2. The comparable ConstraintTest exercise
  3. Custom Constraints and cmp.OrderedTest exercise
  4. Generic TypesTest exercise
  5. When NOT to Use GenericsCode example
  6. Quiz: GenericsQuiz

Lessons in Enums

  1. Enums with const and iotaOutput exercise
  2. A String Method for EnumsTest exercise
  3. Validating Enum ValuesTest exercise
  4. Switching on EnumsTest exercise
  5. Quiz: EnumsQuiz

Lessons in Projects and Final Review

  1. Go ProverbsQuiz
  2. Project: Mini Bank LedgerTest exercise
  3. Project: Warehouse InventoryTest exercise
  4. Final Quiz: Reviewing Every ChapterQuiz

Course catalog

2 courses are ready today. The others are in the works, grouped by where you want to end up.

Two Go gophers building a small robot with a wrench and a hammer (pencil drawing)

Backend

7 courses

Servers, APIs and databases: the part of an app nobody sees.

  • Go, see this course's chapters17 chapters, 97 lessons

    A small, fast language for backends, tools and network services. From variables to generics, then two small projects.

  • Read puzzle input, pick the right data structure and spot the patterns that keep coming back: maps, sets, grids, search, sorting, dynamic programming and graphs. Groundwork for practising on Advent of Code or LeetCode. Nibble is not affiliated with either.

  • PythonComing soon

    Readable syntax for scripts, automation and working with data.

  • JavaScript and TypeScriptComing soon

    The language of the web, from small browser scripts to typed servers.

  • Express and NestJSComing soon

    Building APIs on Node.js, from simple routing to a modular architecture.

  • JavaComing soon

    The object-oriented language behind many company systems and Android apps.

  • Spring BootComing soon

    Backend services in Java: REST APIs, databases and configuration.

Mobile and Apple

3 courses

Apps for the pocket and the wrist.

  • SwiftComing soon

    Apple's safe, expressive language and the base for every Apple course.

  • iOS developmentComing soon

    iPhone apps with SwiftUI, from the first screen to stored data.

  • Apple hardware integrationComing soon

    iPhone, Apple Watch and iPad sensors: motion, location, health and touch.

Cloud and Networking

4 courses

Where apps run and the roads their data travels.

  • CComing soon

    Memory, pointers and how programs talk straight to the machine.

  • NetworkingComing soon

    How data moves: IP, TCP, DNS and HTTP up close.

  • Cloud engineeringComing soon

    Running apps in the cloud: containers, deploys and monitoring.

  • Go, see this course's chaptersSame course as in Backend

Common questions

Golden cookie crumbs up close against a dark background
Is Nibble free?

Yes. Every lesson in every available course is yours to read, run and check without paying a cent.

What do I need to install?

Nothing. The editor and the Go runtime run in your browser, so a laptop, tablet or phone with a modern browser is enough.

Is it for beginners?

Yes. The first chapter starts with your first program and variables. You do not need to have written Go before.

Do I have to log in?

Nope. You can start learning without an account, and your progress and code drafts are saved on this device. Log in only if you want your progress kept in an account, so you can pick up on another laptop, tablet or phone.

What language are the lessons in?

The interface and the lessons are in both English and Indonesian. In the Go course the code keeps its Indonesian names and comments, so you'll see things like nama and harga in the editor; in Problem Solving with Go the code is in English.

When will the other courses arrive?

There are no dates yet. Courses in the catalog are built one at a time, and each opens only when all of its lessons are ready.