Possible Duplicate:
How to generate all permutations of a list in Python
I want to get all possible combination having values range from 0-7.
For eg
arr[0]= 0,1,2,3,4,5,6,7
arr[1]=1,2,3,4,5,6,7,0
arr[2]=2,3,4,5,6,7,1,0
arr[3]= 0,1,2,3,4,5,6,7
arr[4]=1,2,3,4,5,6,7,0
arr[5]=2,3,4,5,6,7,1,0
arr[6]= 0,1,2,3,4,5,6,7
arr[7]=1,2,3,4,5,6,7,0
arr[8]=2,3,4,5,6,7,1,0
arr[9]= 0,1,2,3,4,5,6,7.....
and so on.
I want to get all possible combination with no repeating digits from a given set of value i.e 0-7.