Tag: Golang
9 posts
-
Go in 2 Weeks #05
Go error handling vs C++ try/catch: multiple returns, if err != nil, defer, fmt.Errorf %w, errors.Is/As, panic/recover. Practical examples for production.
-
C++ vs Go: Performance, Concurrency Models, and When to Choose Each
C++ vs Go: performance, concurrency, and practical selection — scenarios, models, pitfalls, and production patterns for backend and systems work.
-
Go Web APIs with net/http: Routing, Middleware, Context, JSON and Database Access
Build production-ready web APIs with Go. Covers net/http, routing, middleware, database access, JSON handling, and deployment best practices.
-
How Go Slices Really Work: Header Layout, append Growth, Shared Backing Arrays and Pitfalls
Go slice internal structure, memory allocation mechanism, capacity vs length, append operation principles, performance optimization techniques.
-
Go in 2 Weeks #04: Interfaces, Duck Typing, any and Type Assertions
Go interfaces vs C++ virtual functions: implicit satisfaction, method sets and receivers, io.Reader/io.Writer, small interfaces, any, type assertions, and type switches.
-
Go in 2 Weeks #06: Goroutines, Buffered vs Unbuffered Channels, select and Worker Pools
Goroutines and channels for C++ developers: the scheduler, unbuffered vs buffered semantics, select and timeouts, worker pools, and deadlocks and leaks.
-
Go in 2 Weeks #01: Go's Philosophy and Core Syntax for C++ Developers
Go tutorial for C++ devs: install Go, := and var, for/range, garbage collection, go fmt, packages, and modules—side by side with C++.
-
Go in 2 Weeks #02: Pointers Without Arithmetic, Slices vs std::vector, and Maps
Go pointers, slices, and maps for C++ developers: safe *T, len/cap/append, map lookup with ok, and how slices differ from std::vector.
-
Go in 2 Weeks #03: Structs, Methods, Pointer vs Value Receivers and Embedding Instead of Inheritance
No class keyword in Go: structs, methods, pointer vs value receivers, embedding, and NewXxx constructors compared to C++.