Author

Tuan Nguyen

Tuan Nguyen

Data Scientist

at · 138 articles published

Proficient in Golang, Python, Java, MongoDB, Selenium, Spring Boot, Kubernetes, Scrapy, API development, Docker, Data Scraping, PrimeFaces, Linux, Data Structures, and Data Mining. With expertise spanning these technologies, he develops robust solutions and implements efficient data processing and management strategies across various projects and platforms.

Areas of expertise

Author profile illustration for Tuan Nguyen — technical writer at GoLinuxCloud
Proficient in Golang, Python, Java, MongoDB, Selenium, Spring Boot, Kubernetes, Scrapy, API development, Docker, Data Scraping, PrimeFaces, Linux, Data Structures, and Data Mining. With expertise spanning these technologies, he develops robust solutions and implements efficient data processing and management strategies across various projects and platforms.

This is page 4 of 5 listing tutorials and guides by Tuan Nguyen. GoLinuxCloud publishes 138 articles from this author on Linux administration, cloud platforms, and DevOps automation.

Articles by Tuan Nguyen

programming

GOPATH vs GOROOT: what is GOROOT, go root, and how they differ

Gopath vs goroot and goroot vs gopath: what is goroot (go root / golang goroot), GOPATH for your workspace, why GOPATH and GOROOT must not be the same directory, go env GOROOT and go env GOPATH, modules and GOMODCACHE, …

Tuan Nguyen5 min read
programming

Golang new error: errors.New, fmt.Errorf, and custom errors

Golang new error and golang create error with errors.New and fmt.Errorf; errors new golang patterns, sentinels, errors.Is, %w wrapping, and custom types implementing error.

Tuan Nguyen4 min read
programming

Golang append to slice: elements, another slice, and []byte rules

Golang append and append golang: golang add to slice, golang append to slice and golang slice append with variadic ..., golang append slice to slice, go append to array semantics, []byte plus string append, and always …

Tuan Nguyen4 min read
programming

Golang init function: syntax, rules, and order of execution

Golang init and go init: func init() rules, init order across imports and files, multiple init functions, blank imports, when to use or avoid init(), with spec-aligned examples.

Tuan Nguyen6 min read
programming

Golang prompt for input: interactive CLI with bufio and fmt

Golang prompt for input and go interactive cli: read lines from stdin with bufio for a go prompt, yes/no prompts, Scanln loops, and validation with strconv; note c-bata go-prompt library vs stdlib for golang prompt and …

Tuan Nguyen5 min read
programming

Go get specific version and go get version with Go modules

Go get specific version and go get version with modules: go get with version and go get package version using @v1.2.3, go list for go get version of package, go update package to specific version with @latest and …

Tuan Nguyen5 min read
programming

Convert io.Reader or io.ReadCloser to a String in Go

Drain a golang io.Reader or io.ReadCloser into a string with io.ReadAll and string(b), or stream with strings.Builder and io.Copy or bytes.Buffer.ReadFrom; use strings.NewReader when you need a reader from a string.

Tuan Nguyen5 min read
programming

Golang remove from slice: delete element by index and while iterating

Golang remove from slice and delete element from slice golang: by index with order, swap-pop without order, first element, and safe patterns while iterating.

Tuan Nguyen4 min read
programming

Convert a Go Byte Slice to io.Reader (and Reader Back to Bytes)

Turn a Go []byte or byte buffer into an io.Reader with bytes.NewReader, use strings.NewReader for text, then read with io.ReadAll or io.Copy when you need bytes or strings back from a reader.

Tuan Nguyen5 min read
programming

Golang HTML to Text: Strip Tags, Parse HTML, and Convert HTTP Body

Convert HTML to text in Go, strip HTML tags, read HTTP response body with io.ReadAll, parse HTML with golang.org/x/net/html, extract body text or body HTML, and know when html2text or bluemonday fits better.

Tuan Nguyen9 min read
programming

Golang URL Encode Decode: QueryEscape, PathEscape, and Query Params

URL encode and decode strings in Go with net/url: QueryEscape, QueryUnescape, PathEscape, PathUnescape, url.Values, ParseQuery, and url.Parse with RawQuery.

Tuan Nguyen6 min read
programming

Golang Type Assertion: Interface, Concrete Type, and Type Switch Examples

Learn how type assertion works in Go on interface values: concrete types, x.(T) vs comma-ok, panic rules, type switches, and how assertion differs from type conversion.

Tuan Nguyen9 min read
programming

Golang remove backslash from string

Remove backslash from a string in Go with strings.ReplaceAll or strings.Replace, including raw literals and optional cleanup. Related: golang remove substring and golang remove characters.

Tuan Nguyen4 min read
programming

Golang reflect and golang reflection: Type, Value, Kind, Set, MakeFunc, StructOf

Golang reflection with reflect.TypeOf and reflect.ValueOf, Kind vs Type, struct fields and tags, settable values and Set, reflect.New, MakeSlice MakeMap MakeChan, MakeFunc wrappers, StructOf limits, Value.Call, …

Tuan Nguyen8 min read
programming

Go json.Unmarshal: Structs, Maps, Slices, null, RawMessage, and Errors

Deep guide to json.Unmarshal in Go: []byte and pointer rules, structs with tags, maps and float64 numbers, slices, nested JSON, any decoding, null, json.RawMessage, unknown fields vs Decoder.DisallowUnknownFields, …

Tuan Nguyen14 min read
programming

Golang Parse JSON: String, File, Struct, Map, and Decoder Examples

Learn how to parse JSON in Go using encoding/json: JSON strings, files, HTTP bodies, structs, maps, nested data, json.Unmarshal, json.Decoder, and common errors.

Tuan Nguyen10 min read
programming

How to Uninstall Golang (Go Compiler) on Linux, macOS, and Windows

Learn how to uninstall Golang (Go compiler) on Linux, macOS, and Windows. This guide explains how to remove Go installed using tarball archives, package managers, Homebrew, or installers, including cleaning environment …

Tuan Nguyen11 min read
programming

Best IDE for Golang: VS Code, GoLand, Neovim, Zed, and More

Compare the best IDEs and editors for Go development: VS Code, GoLand, Neovim, Zed, LiteIDE, Sublime Text, and Emacs—use cases, trade-offs, setup checklist, and legacy tools to avoid.

Tuan Nguyen13 min read
programming

How to PROPERLY upgrade GO version in Ubuntu? [SOLVED]

Step by step instructions to upgrade go in Linux, Windows and MacOS.

Tuan Nguyen5 min read
programming

30+ Golang Interview Questions and Answers

30+ golang interview questions and answers for Junior (Beginner), Middle and Advanced (Experienced) professionals

Tuan Nguyen11 min read
programming

Golang JWT (Json Web Token) Examples

In this tutorial we learned how to create HTTP Server and Client using golang JWT (JSON Web Token)

Tuan Nguyen10 min read
programming

Golang AWS Lambda Example [In-depth Tutorial]

In this series, we will learn how to set up a serverless framework example for Golang and AWS Lambda. First of all, we are going to walk through how to create

Tuan Nguyen12 min read
programming

Golang vs Rust | Which language to choose in

Comparing different aspects of golang with rust programming language

Tuan Nguyen7 min read
programming

Learn Golang Chi to Master the Craft of Web Services

Discover the transformative power of Golang Chi in web development. Our comprehensive guide provides insights and practical knowledge, equipping you to create robust, flexible, and efficient web services, mastering the …

Tuan Nguyen17 min read
programming

How to use goroutine return value?

In this example we will use golang channel to fetch the goroutine return value:

Tuan Nguyen4 min read
programming

Golang SQLite3 Tutorial [With Examples]

Golang sqlite tutorial with CRUD Operation. Executing commands on SQLITE database, Select statement, Insert, Read and Delete Operation with examples

Tuan Nguyen9 min read
programming

Golang Viper: The Unsung Hero of Configuration Wizards

golang viper tutorial to source YAML, JSON or ENV files and get variables. Set default values for empty or missing variables using viper.SetDefault

Tuan Nguyen15 min read
programming

Managing golang connection pool

In the previous article, I introduced to you the ways to work with SQL in Golang. You don't need to change the defaults for the sql.DB connection pool for the

Tuan Nguyen7 min read
programming

Golang generate random string Examples

Multiple examples covering golang generate random string using rand function. Generate alphanumeric, special characters, uppercase, lowercase strings

Tuan Nguyen7 min read
programming

How to check if struct is empty in GO?

This article describes a few methods for determining whether a struct in Go is empty. It includes structs having fields that are comparable and

Tuan Nguyen4 min read