Now I\'ve always heard binary search trees are faster to build from randomly selected data than ordered data, simply because ordered data requires explicit rebalancing to keep t
Aaronaught has done a really decent job explaining this.
For these two special cases, I find it easier to grasp it in terms of the insertion path lengths.
For random input, your insertion path goes down to one of the leaves and the length of the path - thus the number of rotations - are bounded by the height of the tree.
In the sorted case, you walk on the right spine of the treap and the bound is the length of the spine, which is less than or equal to the the height.
Since you rotate nodes along the insertion path and your insertion path is the spine in this case, these rotations will always shorten the spine (which will result in a shorter insertion path at the next insertion, since the insertion path is just the spine etc.)
Edit: for the random case the insertion path is 1.75x longer.