Day 028 — Week 4 + Month 1 Review · Tag v0.1.0¶
Month 1 · Week 4 · ⬅ Day 027 · Journal index
🎯 Learning Objective¶
Close out Week 4 (embedding, generics, the taskcli project) and all of Month 1 with closed-book recall, then ship the v0.1.0 release tag.
📚 Topics¶
- Struct embedding & composition · method promotion / shadowing
- Generics: type params, constraints (
any/comparable/cmp.Ordered/unions) - Generic containers:
Stack[T],Set[T] - Project
taskcli: model + atomic JSON store +flagCLI + tests
📖 Reading / Sources¶
- Re-read my notes for [[Day 022]]–[[Day 027]]
- Go blog — When To Use Generics
- Semantic Versioning 2.0.0
Full write-ups: Week 4 Review · Month 1 Review
📝 Notes¶
- Light day — the detailed synthesis, re-quiz, metrics, and next-month goals live in the week review and month review.
- One-line summary of the week: compose with embedding, generalize algorithms with generics, and tie it together in a tested, dependency-free CLI.
- One-line summary of the month: I went from zero to a solid command of Go fundamentals — syntax, composite types, methods/interfaces/errors, generics — and shipped a real CLI.
- Release: tag the repo
v0.1.0(first public milestone, "Go Fundamentals" complete) —git tag -a v0.1.0 -m "Month 1 complete: Go fundamentals + taskcli".
🏋️ Exercises / Practice¶
| Exercise | Status | Link |
|---|---|---|
All Week-4 exercises green (go test ./...) |
✅ | exercises/month-01/week-4 |
| Closed-book re-quiz (below) | ✅ | — |
🐛 Mistakes Made¶
- On recall I reached for
comparablewhen the body needed ordering — the right answer iscmp.Ordered. Flagged for spaced repetition.
❓ Open Questions¶
- Where do generics stop paying off and an interface read cleaner? Building more containers next month should sharpen the instinct.
🧠 Active Recall (answer without looking)¶
-
Q: Is struct embedding inheritance? What relationship does it create?
A
No — it's **composition** with method/field *promotion* (auto-forwarding). There's no subtype relationship, no virtual dispatch, no `super`; the outer type isn't assignable to the embedded type. -
Q: You need a generic container keyed by its elements. Which constraint, and why?
A
`comparable` — elements are used as **map keys**, which require `==`/`!=`. (`cmp.Ordered` would be needed only if you also compared with `<`/`>`.)
🪶 Feynman Reflection¶
Week 4 was about reuse: embedding reuses behavior by composition, generics reuse algorithms across types, and the project reuses every Month-1 skill at once — structs, methods, interfaces, errors, JSON, files, flags, and tests — in something I can actually run.
🕳️ Knowledge Gaps¶
- Iterators (range-over-func, Go 1.23) for my containers; benchmarks/
-race— both carry into Month 2.
✅ Summary¶
Month 1 ("Go Fundamentals") is complete: 28 daily notes, 4 weekly reviews, a runnable example library, table-driven exercises, and a tested taskcli shipped as v0.1.0.
⏭️ Next Steps / Prep for Tomorrow¶
- Start Month 2 (concurrency & the runtime). See the month review for the plan and the week review for goals.
| Time spent | Difficulty | Confidence |
|---|---|---|
| 75 min | 🟦⬜⬜⬜⬜ | 🟦🟦🟦🟦⬜ |
Suggested commit: docs(journal): week 4 + month 1 review, tag v0.1.0 (day 028)