The topology of E. coli inner membrane proteins depends primarily on the distribution of positively charged residues in the molecule. We have constructed model proteins with four potential transmembrane stretches and have systematically explored the topological effects of lysines placed in the loops connecting the transmembrane spans. Our results indicate that membrane insertion is locally determined, with individual "helical hairpins" inserting independently of each other. Topologically "frustrated" molecules, where the charge distribution is such that different parts of the molecule would prefer to insert with incompatible orientations, adopt "leave-one-out" topologies in which only 3 of the 4 potential transmembrane stretches span the membrane. These results are relevant for our general understanding of both membrane protein biogenesis and the evolution of multi-spanning membrane proteins.