#include<vector>
#include<algorithm>
#include<iostream>
#include<queue>
#include<stack>
#include<functional>
using namespace std;
struct data{

	int first;
	int second;
};
class compare{
public:
	 bool operator()( data &a ,data &b)
	 {
		 if(a.first < b.first) return true;
		 else false;
	 }
};

int main()
{	
	priority_queue <data , vector<data>, compare> heap;
	data temp2[] = { {5,19},{2,7},{90,9},{12,6} };
	
	for(int i = 0; i <  4 ;++i)
	{		
       heap.push(temp2[i]);
	}
	while(heap.empty() == false)
	{
		cout<<heap.top().first<<endl;;
		heap.pop();
	}
	
}