a,b = map(int,input().split())
dic = {}
for i in range(a,b+1):
x = i
m = 1
while len(str(x)) != 1:
c = 1
for j in str(x):
c *= int(j)
x = c
m+=1
dic[i] = m-1
n = max(dic.values())
print(n)
l1 = []
for i in range(a,b+1):
if i in dic and dic[i] == n:
l1.append(i)
print(' '.join(str(i) for i in l1))
pta L1-103 整数的持续性 python
最新推荐文章于 2024-09-10 13:01:50 发布