42
Объяснение:
count = 0
for i in range(3456, 9876):
a = i // 1000
b = i % 1000 // 100
c = i % 100 // 10
d = i % 10
if i % 15 != 0 or '0' in str(i) or '1' in str(i) or '2' in str(i) or a == b or a == c or a == d or b == c or b == d or c == d:
continue
count += 1
print(count)
42
Объяснение:
count = 0
for i in range(3456, 9876):
a = i // 1000
b = i % 1000 // 100
c = i % 100 // 10
d = i % 10
if i % 15 != 0 or '0' in str(i) or '1' in str(i) or '2' in str(i) or a == b or a == c or a == d or b == c or b == d or c == d:
continue
count += 1
print(count)