I have a vector of variants that can store uint64_t and double types, and I want to calculate the median over them. I have found a solution as outlined below but it seems re