package main
func main() {
SyncedMap := Map[string, int]{}
wg := sync.WaitGroup{}
for i := range 100 {
wg.Add(1)
go func(i int) {
SyncedMap.Store(fmt.Sprint(i), i)
wg.Done()
}(i)
}
wg.Wait()
t.Logf(SyncedMap.String())
SyncedMap.Clear()
t.Logf(SyncedMap.String())
}
-
Notifications
You must be signed in to change notification settings - Fork 0
License
telebroad/gsync
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
License
Stars
Watchers
Forks
Packages 0
No packages published