Given a finite discrete set $X \subset \mathbb{R}$ with cardinality $k$.
The are $2^k$ subsets. For any given subset, there is a median associated with it (Define the median of $\emptyset$ as 0).
Wondering if there are any smart ways to get the $2^k$ medians.
The possible medians are:
That makes $k+{k \choose 2}+1 = \frac12k^2 +\frac12k+1$ potentially distinct values for subset medians and explains how to find them; it may turn out that there are some duplicates.