-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest1.cpp
49 lines (45 loc) · 864 Bytes
/
test1.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#include <iostream>
#include <vector>
#include "Vector/Vector.hpp"
#include "Deque/Deque.hpp"
#include <deque>
#include <queue>
#include <algorithm>
// #include "Util/Algorithm.hpp"
#include "Queue/Priority_queue.hpp"
#include <iostream>
int main()
{
ft::deque<int> a;
a.push_front(1);
a.push_front(3);
a.push_front(2);
a.push_front(4);
a.push_front(5);
std::deque<int> d;
d.push_front(1);
d.push_front(3);
d.push_front(2);
d.push_front(4);
d.push_front(5);
ft::priority_queue<int> b;
std::priority_queue<int> c;
for (int i = 4; i > -1; i--)
b.push(a[i]);
for (int i = 4; i > -1; i--)
c.push(d[i]);
while (!b.empty())
{
std::cout << (b.top());
b.pop();
}
std::cout << std::endl;
while (!c.empty())
{
std::cout << (c.top());
c.pop();
}
// (a.begin(), a.end());
// std::cout << (a.end() == itt) << std::endl;
return 0;
}