go-dojo
learn go · earn mastery
phase 1 · 1.5-goroutines-channels

Goroutines, channels, the intentional race

prereqs 1.4-pointers-slices-maps
review intervals 3d 7d 21d 60d drills goroutine-channel, mutex-vs-channel

The lesson for this task hasn't been written yet. The mastery criteria below is the shortest description of what you'll own when this task is green.

Mastery criteria

- Concurrent word counter: chunk → goroutine → channel aggregate
- Demonstrate a data race with `go test -race`; fix with sync.Mutex
- Refactor the same fix with channels; articulate which you'd ship and why
- Contrast: what's different about goroutines vs JavaScript async/await

Verify

Run from your go-dojo repo root:

go-dojo verify 1.5-goroutines-channels

This runs the task's go test suite in exercises/phase-1/1.5-goroutines-channels/, commits the attempt to .go-dojo/attempts/, and updates your mastery.