Compare two columns in excel

There can be a requirement at times to figure out if data present in one column is present in second column of an excel. I found this command handy.

=NOT(ISERROR(MATCH(A1,$B$1:$B$100, 0)))

Source – stackoverflow