Difference between fmt.Println() and println() in Go

前端 未结 5 1699
北海茫月
北海茫月 2020-12-07 12:02

As illustrated below, both fmt.Println() and println() give same output in Go: Hello world!

But: how do they differ from each

5条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-07 12:31

    As for the difference, this is an example.

    println() prints a pointer point to the address of function test.

    fmt.Println() prints the address of function.

提交回复
热议问题