https://www.practical-go-lessons.com/
Category: My Go Tutorial
Interface Type
Interface names conventions By convention, one-method interfaces are named by the method name plus an -er suffix. Define an interface type It start with the keyword “type” follow by the interface name (ended with -er). Begin of a block of code symbol “{“, the function name (eg. Greeting() function and return a string ). One… Continue reading Interface Type
Go (1.15.6 or later) Installation and Setup in Windows 10 (Fresh Install)
Official Go download page, this link gives you more option to choose from OS platform and OS architecture x86-64 build. And you can use the go build command parameter to building a binary for an application that can run for CPU of x86 (386) and x86-64. https://golang.org/dl/ Install Open the MSI file you downloaded and… Continue reading Go (1.15.6 or later) Installation and Setup in Windows 10 (Fresh Install)
Range Over Slice and Map
https://repl.it/join/gdzplzna-shankuo go build ./main1 -> shan kuo2 -> Hoi Leng3 -> Choi Yan4 -> Evelyn Chan
Looping Over Arrays and Slices
https://repl.it/@shankuo/LoopArraySlice go version go1.14 linux/amd64 go run main.goShank KuoHoi LengChoi YanEvelyn Chan
Slice of Slice
https://play.golang.org/p/3HpTAxoPC6l
Create and Print a 2D Slice
https://play.golang.org/p/F5MTsF_Z1J1
Literals in Regular Expression
Literals are the simplest form of pattern matching in regular expressions. They will simply succeed whenever that literal is found. func Match ¶ func Match(pattern string, b []byte) (matched bool, err error) Match reports whether the byte slice b contains any match of the regular expression pattern. Example Code Go Playground https://play.golang.org/p/ts3SyaxKQgF Resources go doc regexp/syntax https://pkg.go.dev/regexp?tab=doc#pkg-overview
Create a Module
https://golang.org/doc/tutorial/create-module
GitHub Guides
https://guides.github.com/