import itertools
houses = [1,2,3,4,5]
orderings = list(itertools.permutations(houses))

print orderings
import itertools
houses = [1,2,3,4,5]
orderings = list(itertools.permutations(houses))

print orderings