cppreference.com > C++ Priority Queues > size
size
Syntax:
  #include <queue>
  size_type size() const;

The size() function returns the number of elements in the current priority queue.