title: python lambda list filtering with multiple conditions
body: <p>My understanding about filtering lists with lambda is that the filter will return all the elements of the list that return True for the lambda function. In that case, for the following code,</p>
  
  <pre><code>inputlist = []
  inputlist.append(["1", "2", "3", "a"])
  inputlist.append(["4", "5", "6", "b"])
  inputlist.append(["1", "2", "4", "c"])
  inputlist.append(["4", "5", "7", "d"])
  
  outputlist = filter(lambda x: (x[0] != "1" and x[1] != "2" and x[2] != "3"), inputlist)
  for item in outputlist: print(item)
  </code></pre>
  
  <p>The output should be </p>
  
  <pre><code>['4', '5', '6', 'b']
  ['1', '2', '4', 'c']
  ['4', '5', '7', 'd']
  </code></pre>
  
  <p>But the output that I get is</p>
  
  <pre><code>['4', '5', '6', 'b']
  ['4', '5', '7', 'd']
  </code></pre>
  
  <p>I get the expected output, if I use </p>
  
  <pre><code>outputlist = filter(lambda x: (x[0] != "1" or x[1] != "2" or x[2] != "3"), inputlist)
  </code></pre>
  
  <p>What am I doing silly here? Or is my understanding not correct?</p>