-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstd_deque.cpp
More file actions
46 lines (36 loc) · 830 Bytes
/
std_deque.cpp
File metadata and controls
46 lines (36 loc) · 830 Bytes
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
/*
* =====================================================================================
*
* Filename: Deque.cpp
*
* Description:
*
* Version: 1.0
* Created: 2016年01月28日 09时47分08秒
* Last Modified: 2016年01月28日 09时47分08秒
* Revision: none
* Compiler: gcc
*
* Author: zt (),
* Organization:
*
* =====================================================================================
*/
#include <stdio.h>
#include <stdlib.h>
#include <iostream>
#include <deque>
int main ( int argc, char* argv[] )
{
std::deque<int> deq;
deq.push_front ( 10 );
deq.push_front ( 11 );
deq.push_front ( 13 );
deq.push_back ( 1 );
deq.push_back ( 3 );
for ( auto& ele : deq )
{
fprintf ( stderr, "%d \n", ele );
}
return 0;
}