Go Structs and Methods

Опубликовано: 26 Июнь 2026
на канале: HooDev
75
8

In this episode of Go from Scratch, we explore structs and methods — the foundation for building custom types and adding behaviour in your Go programs.

You’ll learn:
✅ What a `struct` is
✅ How to define and create structs
✅ How to attach methods to a struct
✅ How to use pointer receivers to modify struct fields
✅ Why Go has methods, even though it isn’t a “fully object-oriented” language
✅ How to call methods like: `alice.Greet()` and `alice.HaveBirthday()`

By the end of this episode, you’ll know how to build your own types in Go and add methods to make them more powerful.

👀 Coming soon: we’ll explore pointers in more depth — so stay tuned!

📺 This video is part of my beginner-friendly Go from Scratch playlist — each episode can be watched independently.
   • Learn Go (Golang) from scratch  

👍 Like, comment and subscribe if you're enjoying the series — and let me know what you’re building with Go!

#golang #gotutorial #programming #golangstructs #golangmethods #learntocode #goobjectmodel #gofromscratch