The average (arithmetic mean) of the 5 positive integers k, m, r, s, and t is 18, and k < m < r < s < t. If t is 40, what is the greatest possible value of the median of the 5 integers?  Choose the correct choice from the following answers:
A) 16  B) 23  C) 19  D) 20  E) 22
We need to find the median which is the third value when the numbers are in increasing order. Since k&lt;m&lt;r&lt;s&lt;t, the median would be r.   The average of the positive integers is 18 which means that in effect, all numbers are equal to 18. If the largest number is 40, it is 22 more than 18. We need r to be maximum so k and m should be as small as possible to get the average of 16. Since all the numbers are positive integers, k and m cannot be less than 1 and 2 respectively. 1 is 17 less than 18 and 2 is 16 less than 18 which means k and m combined are 33 less than the average. 40 is already 22 more than 18 and hence we only have 33 - 22= 
<gadget id="calculator">33 - 22</gadget>
<output>11</output>
11 extra to distribute between r and s. Since s must be greater than r, r can be  18+5= 
<gadget id="calculator"> 18+5</gadget>
<output>23</output>
23 and s can be   18+6= 
<gadget id="calculator">  18+6</gadget>
<output>24</output>
24.   So r is 23   Answer (23)
<result>B</result>
The average (arithmetic mean) of the 5 positive integers k, m, r, s, and t is 18, and k < m < r < s < t. If t is 40, what is the greatest possible value of the median of the 5 integers?