Hi ,
when in the Person Compare comparator class the instructor does
return A.age() <B.age()
then , it should mean that if A 's age is less than B’s age then return true that means A should be placed before B in the priority queue which implies that the priority queue should be a min priority queue(i.e. elements should come in ascending order) .However , the answer is coming in the descending order . Kindly explain this to me .I’m unable to understand this