working on compare()