题解 | #提取不重复的整数#
提取不重复的整数
http://www.nowcoder.com/practice/253986e66d114d378ae8de2e6c4577c1
写这一行字的时间可能都比写这道题长。
res = []
for ch in input()[::-1]:
if ch not in res:
res.append(ch)
print("".join(res))
提取不重复的整数
http://www.nowcoder.com/practice/253986e66d114d378ae8de2e6c4577c1
写这一行字的时间可能都比写这道题长。
res = []
for ch in input()[::-1]:
if ch not in res:
res.append(ch)
print("".join(res))
相关推荐