0

I have a list comprehension that I would like to make it more clear to read:

for a, b in enumerate( f for f in files if 'body'and'psd'in f)

When I try to understand it:

for f in files:
 if 'body'and'psd'in f:
  for a, b in enumerate (f):
   print(a,b)

Is that correct?

Ryan Yeung
  • 45
  • 6
  • 1
    Does this answer your question? [How to test multiple variables for equality against a single value?](https://stackoverflow.com/questions/15112125/how-to-test-multiple-variables-for-equality-against-a-single-value) – SiHa Jan 05 '22 at 10:23

0 Answers0