The problem is
Given a stick of length $L$. You randomly cut it in 2 locations to get 3 sub-sticks. What is the expected length of the shortest, longest, and middle length stick? Note that "middle" here does not mean the segment in the middle of the stick after you cut it at 2 locations. It is referring to the second largest (or equivalent, second smallest) of the 3 segments. So for example, if after cutting and we have that the lengths are $x, y-x, 1-y$, the longest length is $\max(x, y-x, 1-y)$, the shortest is $\min(y, y-x, 1-y)$ and the remaining is the "middle" length.
I've solved the problem for the expected length of the shortest and longest length. And it's pretty obvious that the expectation of the shortest, longest and middle length stick is equal to $L$, so I could compute the expected middle length very easily give expected longest and shortest length.
However, if I didn't already solve for the expected longest and shortest length, and instead want to directly solve for the expected middle length, how would one do that? The first and last order statistic are pretty easy to compute, but the middle one seems it would be rather tedious?
Cutting in two random places of a length $L$ stick corresponds to picking a random point in an $L\times L$ square. You can divide this square into regions depending on whether it is the left, right or middle piece that has middle length. Define a function from the square to the real numbers as the length of the middle length segment.
Integrate this function over the square, divide by $L^2$, and you're done. The integral on each region of the square should be rather easy.