title: How to set value to a cell filtered by rows in python DataFrame?
body: <pre><code>import pandas as pd
  
  df = pd.DataFrame([[1,2,3],[4,5,6],[7,8,9],[10,11,12]],columns=['A','B','C'])
  df[df['B']%2 ==0]['C'] = 5
  </code></pre>
  
  <p>I am expecting this code to change the value of columns C to 5, wherever B is even. But it is not working. </p>
  
  <p>It returns the table as follow</p>
  
  <pre><code>    A   B   C
  0   1   2   3
  1   4   5   6
  2   7   8   9
  3   10  11  12
  </code></pre>
  
  <p>I am expecting it to return</p>
  
  <pre><code>    A   B   C
  0   1   2   5
  1   4   5   6
  2   7   8   5
  3   10  11  12
  </code></pre>