GOLANGTESTS Telegram 423
Что выведет код ?

package main

import "fmt"

func main() {
done := make(chan bool)

values := []string{"a", "b", "c"}
for _, v := range values {
go func() {
fmt.Println(v)
done <- true
}()
}

// wait for all goroutines to complete before exiting
for _ = range values {
<-done
}
}


📌Ответ


@golangtests
👍71



tgoop.com/golangtests/423
Create:
Last Update:

Что выведет код ?

package main

import "fmt"

func main() {
done := make(chan bool)

values := []string{"a", "b", "c"}
for _, v := range values {
go func() {
fmt.Println(v)
done <- true
}()
}

// wait for all goroutines to complete before exiting
for _ = range values {
<-done
}
}


📌Ответ


@golangtests

BY Go tests




Share with your friend now:
tgoop.com/golangtests/423

View MORE
Open in Telegram


Telegram News

Date: |

Hashtags Commenting about the court's concerns about the spread of false information related to the elections, Minister Fachin noted Brazil is "facing circumstances that could put Brazil's democracy at risk." During the meeting, the information technology secretary at the TSE, Julio Valente, put forward a list of requests the court believes will disinformation. best-secure-messaging-apps-shutterstock-1892950018.jpg 4How to customize a Telegram channel? Although some crypto traders have moved toward screaming as a coping mechanism, several mental health experts call this therapy a pseudoscience. The crypto community finds its way to engage in one or the other way and share its feelings with other fellow members.
from us


Telegram Go tests
FROM American