title: Does changing a priority queue element result in resorting the queue?
body: <p>I have a priority_queue, and I want to modify some of it's contents (the priority value), will the queue be resorted then?</p>
  
  <p>It depends if it resorts on push/pop (more probable, becouse you just need to "insert", not resort whole), or when accessing top or pop.</p>
  
  <p>I really want to change some elements in the queue. Something like that:</p>
  
  <pre><code>priority_queue&lt;int&gt; q;
  
  int a=2,b=3,c=5;
  int *ca=&amp;a, *cb=&amp;b, cc=&amp;c;
  
  q.push(a);
  q.push(b);
  q.push(c); //q is now {2,3,5}
  
  *ca=4;
  
  //what happens to q?
  // 1) {3,4,5}
  // 2) {4,2,5}
  // 3) crash
  </code></pre>