package main import ( "fmt" ) func main() { for i := 0; i < 10; i++ { } var arr []int for index, val := range arr { fmt.Println(index, val) } a := 10 if a > 10 { } else { } switch a { case a: fmt.Println("dadsa"); break; } } //多参数返回 func add(num, num2 int) (string, int) { return "num+num2=", num + num2 } //不限数量参数传入 func multiParams(s ...int) { fmt.Println(s) }