美团笔试第二题数字字符串python
a = '22'
num_lis = [int(i) for i in a]
dict1=[0 for i in range(10)]
#num_lis.sort()
for i in num_lis:
dict1[i] = dict1[i]+1
dict1[0]=max(dict1)+1
#美团##笔试题目#
num_lis = [int(i) for i in a]
dict1=[0 for i in range(10)]
#num_lis.sort()
for i in num_lis:
dict1[i] = dict1[i]+1
dict1[0]=max(dict1)+1
print int((1+min(dict1))*str(dict1.index(min(dict1))))
# 题目就不说了 90% ac