I have two python lists. For example:
a = ['1', '2', '3', '4']
b =['1,2', '3,4', '3,33,34', '44']
I need to compare whether list[0] which is one is in b[0] which is 1, 2 and it has to return the output as 1 if it is present and 0 if it is not present.
The final output should be like:
1 (as 1 is present in 1,2)
0 (as 2 is not present in 3,4)
1 (as 3 is present in 3,33,34)
0 (as 4 is not present in 44)
Please do help me in writing a code for this in python as I'm a beginner in this.