The p-trap is full before you start. The trap can only hold so much water, so any added water passes right through. Without the constant water seal, you would have sewer smell floating up in your face. Cool huh?

Basically, gravity is doing it's thing. The water pushing down from the sink or whatever fixture takes the path of least resistance by being pushed through the trap and out, but because of the U-shape, some stays 'trapped' there to seal the fixture from the sewer gasses. That's one reason why it is so critical to keep the angles and distances correct for it all to work right.

Like Terry mentioned hopefully the p-trap is full before new draining water in introduced.
The trap can only hold so much water. So as new water is introduced to the trap, this new(falling) water has kinetic energy. Being that all water is seeking its lowest potential(thanks to gravity) and with the proper slope of the trap arm, the displaced water will flow from the energy it obtained from the falling (draining) water.

Waater is a liquid, so it "seeks its own level". Any water added to one side side of the trap will cause the other side to try to reach the same level, but since there is no barrier to contain it, the water flows down the drain. In the meantime the added water also dropping to maintain an even level with the outlet. When the water stops flowing, the two sides will be in equalibrium and the trap will still be full of water. If the "P" trap is not vented properly, then it becomes an "S" trap with a completely different set of dynamics.