#不同的四位数
count=0
list=[1,2,3,4,5]
for i in list:
for j in list:
for y in list:
for s in list:
if i!=j and j!=y and y!=s and s!=i:
count=count+1
print(str(i)+str(j)+str(y)+str(s), end="\t")
print("一共有多少种{}方案".format(count))
#不同的三位数
count=0
list=[1,2,3,4,5]
for i in list:
for j in list:
for y in list:
if i!=j and j!=y and y!=i:
count=count+1
print(str(i)+str(j)+str(y), end="\t")
print("一共有多少种{}方案".format(count))