Not sure about a single formula solution at the moment... but here is a way with some helper rows...

Assuming your data is in A1:C2

then in A3:

=IF(ROWS(A$3:$A3)>A$2,"",A$1) copied down as far as the most number of votes you would receive.

Then copy formulas to columns B and C

Then use: =MEDIAN(A3:C33)

where I have assumed up to 30 possible number of votes (ie. formula was dragged down to Row 33)

Maybe also possible with VBA.. but don't know how.