Created
March 9, 2021 07:06
-
-
Save velotiotech/2a57d7a0043f6bb2de035413fad20c82 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func main() { | |
fmt.Println("Main started...") | |
//create channel of int | |
c := make(chan int) | |
// call to goroutine | |
go printChannelData(c) | |
// put the data in channel | |
c <- 10 | |
fmt.Println("Main ended...") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment