The answer to 'what causes P-trap' is a P-trap is a curved section of plumbing pipe installed under a sink or other fixture. Its purpose is to create a water seal that prevents sewer gases from entering the home. The curved shape of the P-trap allows water to collect and create this seal, preventing odors from backing up through the drain.
P-traps are an essential component of a properly functioning plumbing system. They help maintain sanitary conditions by blocking the flow of harmful gases and preventing the spread of unpleasant odors throughout the home.