# Sample $k$ of $n$ numbers (with replacement), what is the probability for a certain from the $n$ numbers to be the median of the $k$ numbers [closed]

Suppose we have ordered numbers $$a_1 < a_2 < \dots < a_n$$. Now we sample $$k$$ of them with equal probability and with replacement and compute the median of these and call it $$m$$. (Let us assume that $$k$$ is odd for the sake of simplicity.) What is the probability the $$m = a_i$$ for each $$i$$?

I want to know this to construct the probability mass function for the median of $$k$$ random draws from a sample of $$n$$ numbers.

(Already asked here but does not seem to be simple.)

## closed as off-topic by Matt F., user44191, LSpice, Pace Nielsen, YCorMay 10 at 8:20

This question appears to be off-topic. The users who voted to close gave these specific reasons:

• "MathOverflow is for mathematicians to ask each other questions about their research. See Math.StackExchange to ask general questions in mathematics." – LSpice, Pace Nielsen, YCor
• "This question does not appear to be about research level mathematics within the scope defined in the help center." – Matt F., user44191
If this question can be reworded to fit the rules in the help center, please edit the question.

• I think this belongs on MathStackExchange, and I answered it there. – Matt F. May 7 at 11:53
• Thanks for answering on MathStackExchange (find link in question)! – janlo May 8 at 8:55