ASAditya Singhinadityakumarsingh.hashnode.dev路Jan 21 路 6 min readSOLID Principles 馃挭The significance of SOLID Principles is that it helps us to write code that doesn鈥檛 collapse under its own weight as the project grows. Golang code examples are attached to explain each principle. 1.) Single Responsibility Principle SRP states that C...00
ASAditya Singhinadityakumarsingh.hashnode.dev路Jul 18, 2024 路 2 min readMaps in GoGo provides the Map data structure when 2 values need to be associated with each other. They are stored in a key-value format. Map Format Map is written as map[key-Type] value-Type Map Declaration Let's see how we can declare a map, First we can use...00
ASAditya Singhinadityakumarsingh.hashnode.dev路Apr 24, 2024 路 3 min readSlices in GoGreetings Folks, Slices are a reference to an array, providing more flexibility for the developers to work with these data structures. This allows you to work with a portion of an array as if it were an independent array. Arrays have a fixed size whi...00
ASAditya Singhinadityakumarsingh.hashnode.dev路Apr 18, 2024 路 2 min readDefer Keyword in GoGreetings folks, In this article, we are going to see the use of defer keyword in Go. In simple words, to schedule the execution of a function after other functions have been executed defer is used. package main import "fmt" func main() { fmt.Pr...03RHA