When inspecting a home for the first time I start with the exterior. As I'm taking it in I'm on the look out for bathroom windows and possible fan vents. If I don't see them I make a mental note to check and ensure they are properly vented to outside air.
Bathroom fans not properly vented may lead to moisture / mold in the attic space. Please note, most attics have moisture in them. Main reason has to do with warm house and cold air in attic space. Long list of reasons but, that another story.
Enclosed are a few examples I see and a description of the issues.
Above, fan missing exhaust pipe
This one the installer ran directly into the insulation. As you can see it was trying to burn the house down.
We have a pipe, but it's not reaching outside air. A closer look reveals moisture stains on the sheathing above.
What you looking at here is the bathroom fan duct taped into the overhead stove vent. Hope when you using the bathroom fan as a courtesy, you also have the kitchen stove vent fan on. Otherwise guess where it's going to end up? Handy man venting...needs repair.
Notice the black stains on the sheathing above? Moisture
part 1 of 2, note the stains on sheathing.
Due to such a long run the middle of the pipe filled with water. The problem is we're trying to exhaust warm moisture from the bathroom through a pipe about 15 feet long. As soon as the warm air hits the cold air in the attic it changes the moist air vapor into water. The clogged pipe caused the stains.
Ideally you want the pipe short and go from the fan to the exterior as quickly as possible.
The white stains along the roof rafters is live active mold. Not what you want, this attic needs mold remediation.
Bottom line, if you don't know how to vent your bathroom fan to the exterior have a qualified contractor do the work. It could save you money and your health.