题解 | #删除字符串中出现次数最少的字符#
删除字符串中出现次数最少的字符
http://www.nowcoder.com/practice/05182d328eb848dda7fdd5e029a56da9
while True:
try:
s=input().strip()
#出现次数最少是
l=len(s)
for i in set(s):
n=s.count(i)
if n<l:
l=n
#结合非出现次数最少的字符
ns=''
for i in s:
if s.count(i)!=l:
ns+=i
print(ns)
except:
break