Let's say you do the following:
for row in myListofLists: if tuple(row) in myDictWithTupleKeys: in other words, within a loop through the rows of an n x n array, you check to see if a row is contained as a key within a dict. Is this an O(n^2) operation? In other words, is the in operator an O(n) operation here?
tuple(row)is already O(n) anyway.