isinstance(obj, typename)
예제
l = range(1, 20) if isinstance(l, list): print 'list' else: print 'not list'