title: Comparing 2 columns of two Python Pandas dataframes and getting the common rows
body: <p>I have 2 Dataframe as follows:</p>
  
  <pre><code>DF1=
      A    B   C    D
  0   AA   BA  KK   0
  1   AD   BD  LL   0
  2   AF   BF  MM   0
  
  DF2=
      K    L
  0   AA   BA
  1   AD   BF
  2   AF   BF
  </code></pre>
  
  <p>At the end what I want to get is:</p>
  
  <pre><code>DF1=
      A    B   C    D
  0   AA   BA  KK   1
  1   AD   BD  LL   0
  2   AF   BF  MM   1
  </code></pre>
  
  <p>So, I want to compare two dataframe, I want to see which rows of first data frame (for column A and B) are in common of of second dataframe(Column K and L) and assign 1 on the coulmn D of first dataframe.</p>
  
  <p>I can use for loop, but It will be very slow for large number of entries.  </p>
  
  <p>Any clue or suggestion will be appreciated.</p>