Welcome to my Golang Learning Repository! π This repository contains structured lessons on various Go programming topics, each organized into lesson folders with accompanying problem-solving exercises.
The repository follows a structured format where each topic is stored in its respective lesson folder, along with a separate problem folder for practice.
π¦ Golang-Learning
βββ π lesson_01 # Hello World
βββ π lesson_02 # Types
βββ π lesson_03 # Variables
βββ π lesson_04 # Control Structures (if-else & loops)
βββ π lesson_05 # Maps, Slices & Arrays
βββ π lesson_06 # Functions, Panic & Recover
βββ π lesson_07 # Pointers
βββ π lesson_08 # Structs & Interfaces
βββ π lesson_09 # Concurrency
βββ π lesson_10 # Packages
βββ π lesson_11 # Inbuilt Packages
βββ π problems # Practice Problems
βββ README.md
- Introduction to Go syntax
- Writing and running a basic Go program
- Understanding Go's type system
- Primitive types: int, float, string, bool, etc.
- Declaring and initializing variables
- Short variable declarations
- Constants
- Conditional statements (
if-else
) - Loops (
for
,range
)
- Working with arrays
- Slices and their dynamic nature
- Maps for key-value storage
- Defining and calling functions
- Multiple return values
- Error handling with
panic
andrecover
- Understanding pointers and memory addresses
- Using pointers with functions
- Defining structs for custom data types
- Implementing interfaces for abstraction
- Learnt about it and how it works
- Learnt about channels in go
- Implemented how two concurrent function can talk to each other
- What are packages
- Learnt how to create a packages and use them in a project
- Learnt about testing packages using go testing library
- Learnt about fmt,io,os, http
- Learnt how server can be easily created in go
The problems folder contains coding challenges related to each lesson to reinforce learning through hands-on practice.
- Clone the repository:
git clone https://github.com/walonCode/learning_go.git
- Navigate into the project folder:
cd learning_go
- Run Go programs using:
go run lesson_01/main.go
- Build a strong foundation in Golang
- Write clean, efficient, and idiomatic Go code
- Solve real-world problems using Go
- Concurrency (goroutines & channels)
- File handling
- Web development with Go
- And more!
Happy coding! π