Guest User

Untitled

a guest
Jan 31st, 2014
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.20 KB | None | 0 0
  1. def foo (lst):
  2.     st = " ".join(["%s" % v for v in lst])
  3.     out = []
  4.     for i in lst:
  5.         if st.count(str(i)) > 1:
  6.             out.append(i)
  7.     return out
  8. print foo([10,9,10,10,9,8])
Advertisement
Add Comment
Please, Sign In to add comment