#include <iostream>
#include <deque>
#include <string>
#include <iterator>
using namespace std;
template<class T, class D>
class Member
{
public:
Member(T t, D d) : name(t), sal(d) {}
void print()
{
cout << name << " " << sal << endl;
}
private:
T name;
D sal;
};
int main ()
{
typedef Member<string,double> M;
deque<M> d;
d.push_back(M("Linda",75000));
d.push_back(M("Robert",60000));
deque<M>::iterator It = d.begin();
cout << "Entire deque:" << endl;
while ( It != d.end() )
(It++)->print();
cout << endl;
cout << "Return from front()" << endl;
d.front().print();
return 0;
}