Sums of Consecutive Integers
Python, 67 bytes

f=lambda n,R=[1]:n-sum(R)and f(n,[R+[R[-1]+1],R[1:]][sum(R)&gt;n])or R

An oddly straightforward strategy: search for the interval R with the right sum.

If the sum is too small, shift the right endpoint of the interval up
one by appending the next highest number.
If the sum is too large, shift up the left endpoint by removing the smallest element
If the sum is correct, output R.

Since the bottom end of the interval only increases, longer intervals are found before shorter ones.