gitlab.com/evatix-go/core@v1.3.55/converters/IntegersToMap.go (about)

     1  package converters
     2  
     3  func IntegersToMap(inputArray *[]int) *map[int]bool {
     4  	length := len(*inputArray)
     5  	hashset := make(map[int]bool, length)
     6  
     7  	for _, s := range *inputArray {
     8  		hashset[s] = true
     9  	}
    10  
    11  	return &hashset
    12  }