[Go/Golang] Go언어 조건문 (if/else)
이제 조건문이다 조건문에는 if/else랑 switch가 있다 https://gobyexample.com/if-else Go by Example: If/Else Branching with if and else in Go is straight-forward. package main import "fmt" func main() { Here’s a basic example. if 7%2 == 0 { fmt.Println("7 is even") } else { fmt.Println("7 is odd") } You can have an if statement without an else. if 8%4 == 0 { fm gobyexample.com 먼저 if/else 부터보면 package main import "..
2022.06.09