title: How to compare two columns in R data frame and return 0 or 1 in the third column based on the comparison?
body: <p>I have a dataframe with two columns(both are dates) and a million rows. I have to compare both the dates and return value in the third column. i.e if date in column A is greater than date in column B, return 1 in column C.</p>
  
  <p>Thanks in advance :) </p>