package learning import ( "fmt" "runtime" ) func SwitchCase() { fmt.Println("Go runs on: ") switch os := runtime.GOOS; os { case "darwin": fmt.Println("OS X") case "linux": fmt.Println("Linux") default: fmt.Printf("%s. \n", os) } }