Max value in priority queue java by PriorityQueue maxPriorityQueue = new PriorityQueue<>((a,b) -> b - a); Please follow and like us: