Tag Archives: functions

Golang: pointers – detailed overview

20 April 2019

 What is the pointer? Shortly, the pointer is a variable which stores an address of another variable, where some data is stored. A pointer example Let’s take the simplest example where a pointer is used: package main import “fmt” func main() { a := 1 b := &a fmt.Println(“A: “, a) fmt.Println(“B: “, b) fmt.Println(“B:… Read More »