An S-trap is a particular kind of plumbing trap with a "S" form that keeps sewer gases out of a building. It is not as popular as the P-trap, the plumbing trap that is utilised the most frequently.
A P-trap is a particular kind of plumbing trap with a "P" form that keeps sewer gases out of a building. Because of its "P-trap" shape, it is known as such.
Both the S-trap and the P-trap function by sealing off the drainpipe with water. Gases can safely vent to the outside of the building since the water in the trap prevents the gases from passing through.
The form is the primary distinction between an S-trap and a P-trap. Both the S-trap and the P-trap have a "S" or "P" form. The shape is the only important distinction between the two kinds of traps.