Python code:
flag=0
a=[0,5]
for a1 in range(1,10):
for a2 in range(0,10,2):
for a3 in range(0,10):
for a4 in range(0,10):
for a5 in a:
for a6 in range(0,10):
if ((a1+a2+a3)%3)==0 and ((10*a3+a4)%4)==0 and ((100000*a1+10000*a2+1000*a3+100*a4+10*a5+a6)%6)==0:
flag+=1
print(flag)
答案:1200
沒有留言:
張貼留言