A simple introduction: Go is a new language, a concurrent, garbage-collected, fast-compiling language. It has the following characteristics:
It can compile a large go program in a few seconds on a single computer. Go provides a model for software construction that makes dependency analysis easier and avoids the beginning of most C-style include files and libraries. Go is a static type of language, and its type system has no hierarchy. So users don't need to spend time on defining relationships between types, which makes them more lightweight than typical object-oriented languages. Go is a completely garbage-collected language and provides basic support for concurrent execution and communication. According to its design, go intends to provide a method for the construction of system software on multicore machines.
This study is in the CENTOS7 environment, the operating system is not required, memory enough CPU can run without the premise of
1, to Golang official website download Go package: https://golang.org/dl/
Download and unzip to/usr/local/, generate go Directory
New Gopath Directory
Mkdir-p/mnt/wwwroot/gofile
Vim/etc/profile
Export Goroot=/usr/local/go
Export gobin= $GOROOT/bin
Export path= $PATH: $GOBIN
Export Gopath=/mnt/wwwroot/gofile
: Wq Save
Make it effective
Source/etc/profile
To see if the configuration was successful
Go version
Go version go1.7.1 linux/amd64
Simple test:
Cd/mnt/wwwroot/gofile
Vim Hello.go
Package Main
Import "FMT"
Func Main () {
Fmt. Println ("Hello, World")
}
Go Run hello.go
Hello, World
2, here need to install a Go Language integrated coding program, Goland more convenient and better to see?
Official website: https://www.jetbrains.com/go/features/Download the version of Windows, the simple configuration after the fool installation can write go program!
Activation Code Baidu casually find a, here Link:
https://blog.csdn.net/qq_17088237/article/details/79403548