Golang是一门简洁、快速、安全、开源的编程语言。首先,在开始之前,我们需要安装两个东西:
- 1:Golang
- 2: Vs Code
我们去 Golang 官网下载Goalng所需的运行环境,


下载完成后,直接双击即可


安装完成后,在cmd命令行执行 go version 会出现以下的提示
C:\Users\wmymt>go version
go version go1.15.6 windows/amd64
接下来的vscode的安装过程就不说了,直接下一步即可。现在,我们就在VsCode中安装Golang插件

这样一来,我们的基本工作就做完了。接下来就是按照官网的提示,进行一个小练习

这里,我们先用Vscode新建一个文件。命名为 hello.go ,然后亲手敲入示例中的代码。
package main
import "fmt"
func main() {
fmt.Println("Hello, World!")
}
在我们编写代码后,vs code会进入如下提示,我们点击 install all 即可,但是,默认情况下,肯定会失败的


因为我们访问不到 这个地址,所以我们要修改一下这个地址,这里,我们直接将配置放在用户环境变量中。


点击新建,分别新建 GO111MODULE 和 GOPROXY ,其值分别为 on 和

两个变量新建好后,我们再来安装一次就可以成功安装了

现在,我们就可以用vscode来进行编码可调试了

好了,这次就分享这么多,明天,我们就开始来学习Golang语言的基础语法了。如果还有不明白的地方请留言,如果有哪些地方表述不清楚,或者表达不对的地方,请批评指正,