package main
import "fmt"
func main() {
var a int= 20
var ip *int
ip = &a
fmt.Printf("a address: %x
", &a )
fmt.Printf(" the adrress that ip stored: %x
", ip )
/*I try to get the address of variable ip */
fmt.Printf(" the address of ip: %d
", &ip )
}
go run a.go
result:
a address: c420016078 the adrress that ip stored: c420016078 the address of ip: 842350510120
my question is : is 842350510120 correct address of ip?