I have a DataFrame
with 2 columns, A
and B
, and then a list of values called C
.
I need my code to check whether each value in df.B
is in list C
, and for all that are True
then return the corresponding values from df.A
to a list.
I've tried using a for
loop, and later found the .isin()
function but just can't figure out how to utilize either of these in a way that'll give me the result I need.