MCPcopy Create free account
hub / github.com/austingebauer/go-leetcode / sliceToSet

Function sliceToSet

find_the_difference_of_two_arrays_2215/solution.go:23–29  ·  view source on GitHub ↗
(a []int)

Source from the content-addressed store, hash-verified

21}
22
23func sliceToSet(a []int) map[int]struct{} {
24 s := make(map[int]struct{})
25 for _, v := range a {
26 s[v] = struct{}{}
27 }
28 return s
29}

Callers 1

findDifferenceFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected