Conditional evaluation of several lists in Python

This could help: