Using Compare class in Priority Queue

Why it is compulsory to use round bracket operator overloading inside this compare class. It was not clear in the video. can someone please help?

it is how the syntax has been pre defined in the stl library, u will have to stick to it and there is no way around it

if your question is, why the comparator class at all, it is to use a custom comparison according to the programmer’s choice
to provide flexibility in comparing different elements of diff datatypes