The file Integers holds 100,000 positive integers. We need to find the middlemost integer - the integer in the 50000th position ranking in descending order.
In the first traversal, compute the range where the median is located and its ranking in this range. Because the number of groups is not great after the range is divided, use the function groups for grouping and summarizing. The median can be computed out in the second traversal. In the computation, you are not required to retrieve all data all at once. This method can be used to find the median for whatever amount of data.
In B6, the median is found ultimately, as shown below: