第一個 GO 程式
輸入以下來建立資料夾
mkdir -p $GOPATH/src/github.com/user/hello
新增 hello.go
package main
import "fmt"
func main() {
fmt.Println("Hello, world.")
}
執行:
go run hello.go
Last updated
Was this helpful?
輸入以下來建立資料夾
mkdir -p $GOPATH/src/github.com/user/hello
新增 hello.go
package main
import "fmt"
func main() {
fmt.Println("Hello, world.")
}
執行:
go run hello.go
Last updated
Was this helpful?