The tops are usually OK because you either fit post caps or saw them at an angle to allow runoff. That's why you use triangular rails on fencing too.
The worst thing you can do (as far as rot is concerned) is have flat horizontal areas of timber to collect water like many decks are.
If you want rot free posts use concrete (even concrete rots, but not usually in a lifetime).