//0. organizing code with package in golang
// go語言用包來組織代碼,
//1. package name with main function must be main.
// 包含main函式的包名必須是main,
package main
//2. key word import tells compiler which packages to import.
// import 告訴編譯器匯入哪些包,
import "fmt"
//3. define main function. 定義main 函式
func
main() { //4. '{' must be this line of function name. 括號必須和函式名在同一行
//5. do not need ';' after statement. 陳述句后不需要分號
fmt.Println("Hello, Golang World!")
}
//6. comment is same with c lang 注釋與c語言相同
// use '//' with line and use '/* ...... * /' with block
//7. use the followed command to run go program
// 用下面的命令運行go程式
/*
go run hello.go
*/
轉載請註明出處,本文鏈接:https://www.uj5u.com/qukuanlian/240864.html
標籤:區塊鏈
