You would calculate the dependent rates of the two UDD ones as per normal (as if there were just 2 decrements) - they 'take place' before the one at the end. After reducing the in-force lives by the first 2 UDD decrements, then apply the one concentrated at the end to the remaining lives.
The number of lives exiting due to this decrement at the end divided by the number in force at the start of the period (before the other two decrements) will be the dependent rate.
Conversely, similar logic holds for decrements at the start that apply before the other decrements.
You are correct that you treat it differently, but the rest as per normal, and then just apply the concentrated decrement in the right order, first or last.