#includeIn the above example code, we have created an empty priority queue of integers and then inserted some elements in it using the "push()" method. Then we have checked the size of the priority queue using "size()" method. Finally, we have extracted the maximum element from priority queue using "top()" method and then removed it from the queue using "pop()" method until the queue became empty. The library used in this example is "#include using namespace std; int main() { priority_queue pq; // create an empty priority queue // inserting elements in the priority queue pq.push(10); pq.push(20); pq.push(30); pq.push(40); // check the size of the priority queue cout << "Size of Priority Queue: " << pq.size() << endl; // extract the maximum element from priority queue while (!pq.empty()) { cout << pq.top() << " "; pq.pop(); } return 0; }