Farts are mostly made up of five odorless gasses: nitrogen, hydrogen, carbon dioxide, methane and oxygen.
The foul smell of a fart comes from small amounts of skatole (feces) and sulfur compounds, which are released by bacteria in the intestines. Foods rich in sulfur--like eggs, cauliflower, and meat--can produce smelly farts, while fruits, vegetables and beans usually don't.