Use tuples instead of lists for checks
Use generator instead of list