CALS NOTE

  • Home
  • Archives
  • Cheatsheets
  • rss
  • About
  • Friends
2018-01-05 Calvin Lam
Comments

Go Programming Language

GoLang

Installation

1
2
3
4
5
6
# download: https://golang.org/doc/install

# set Path
export PATH=$PATH:/usr/local/go/bin
export GOROOT=$HOME/go1.X
export PATH=$PATH:$GOROOT/bin

Source code

1
2
3
4
5
6
7
package main

import "fmt"

func main() {
fmt.Printf("hello, world\n")
}

Compile

1
2
cd $HOME/go/src/hello
go build

Execute

1
2
./hello
# output: hello, world
  • Go
  • Installation
Newer
Bad Sector and MySQL innodb
Older
Serverless JAMstack

CALS NOTE

© 2020 Calvin Lam
Modify from Apollo theme, designed by SANOGRAPHIX.NET
Powered by Hexo