티스토리 뷰

Development/Go

Go 기초

juniz 2020. 8. 23. 03:01
반응형

Characteristic

  1. Simple
  2. Fast compiling speed, Cross-compiling
  3. Concurrency
    1. Goroutine - Execution
    2. Chanel - Communication
    3. Select - Coordination
  4. Error Handling
val, er := Get()
if err =! nil {
	//error handling
}

 

Go keywords

break default func interface select

case defer go map struct

chan else goto package switch

const fallthrough if range type

continue for import return var

 

 

Install Go [link]

Init mode `go mod init <name>`

 

Hello World

Terminal : `mkdir helloworld`

package main

import "fmt"

func main() {
	fmt.Println("Hello, World")
}

To rn : `go run helloworld`

 

반응형
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2025/12   »
1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31
글 보관함
반응형