Go already supports generics - the hashmap is generic, and the array is generic.
It's just you can't implement your own hashmap in Go, and make it compile time type safe.
It's just you can't implement your own hashmap in Go, and make it compile time type safe.
Then it doesn't support generics. That is the entire point of the feature.
no, Go doesnt' support generics.
Perhaps there are other ways, but in C you have parametric polymorphism functionality through macros. That's why min() and max() are not functions but macros and they work with any type that can be compared, not just float64.