SyntaxFix
Write A Post
Hire A Developer
Questions
This will do it in one line.
>>> a=[2,3,4] >>> b=[1,2] >>> bool(sum(map(lambda x: x in b, a))) True