Refactor code for Find Mode
Refactor code for Calc Median