Created
October 8, 2020 11:36
-
-
Save ampulhetadosaber/21ce3cc86bcc835f8241864f92eebe8f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
priority_queue<int> fila; | |
fila.push(3); | |
fila.push(1); | |
fila.push(2); | |
fila.pop(); // Remove o primeiro elemento da fila, ou seja, o 3. | |
cout << fila.top() << "\n"; | |
// O programa irá imprimir o número 2, | |
// que é agora o elemento da frente |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment