The average of the five numbers is 43. If the five numbers are arranged in ascending order, the average of the first three numbers is 35, and the average of the last three numbers is 50. What is the middle number?
五个数的平均数是43，如果说把这个五个数从小到大排列，那么前三个数的平均数是35，后三个数的平均数是50，则中间的那个数是多少？
<gadget id="calculator">35 * 3</gadget>
<output>105</output>

<gadget id="calculator">50 * 3</gadget>
<output>150</output>

<gadget id="calculator">43 * 5</gadget>
<output>215</output>

<gadget id="calculator">150 - 215</gadget>
<output>-65</output>

<gadget id="calculator">105 + (-65)</gadget>
<output>40</output>

<result>40</result>