add equals method to compare two tasks