Channel

Run Settings
LanguageGo
Language Version
Run Command
// You can edit this code! // Click here and start typing. package main import ( "fmt" ) func main() { //== Channel // messages := make(chan string) // go func() { // messages <- "ping" //}() //wadahMessage := <-messages //fmt.Println(wadahMessage) //== Time Sleep //for i := 0; i < 10; i++ { // fmt.Println("CEK") // time.Sleep(time.Second * 5) //} //== Deadlock Channel messages := make(chan string, 1) messages <- "ping" msg := <-messages fmt.Println(msg) }
Editor Settings
Theme
Key bindings
Full width
Lines