if I want to use generics in function definition, ...
# getting-started
i
if I want to use generics in function definition, do I must need to put a <T> before the function's name like fun <T> whatever(x: T, y: T) ?
k
Either that or the generic argument comes from the containing class.
s
It’s similar to declaring a typevar if you’ve used generics with python’s type annotations