#!/usr/bin/python #coding=gb2312 items=['aaa',111, (3.4) ,2.03]; tests=[(3.4),112]; for key in tests: if key in items: print "yes"; else: print "NO"; res=[]; for key in items: if key not in tests: res.append(key); print res;