order in stl queue container : <p>I'm trying to make a queue of a class that uses a template, but when I try to use the functions front or back I get an error saying that the operator "&lt;&lt;" doesn't match the function. But if I use the function size, for example, it works fine. So, I was wondering that maybe it is because of the order in objects in the queue? I already tried to overload the &lt;&lt; operator but didn't work. Thanks for any help.
Here's my code:</p>

<pre><code>//STL queue container
queue&lt;stackType&lt;int&gt;&gt; stack5;

stack5.push(5);
stack5.push(8);
stack5.push(6);

cout &lt;&lt; "The front element of stack5 is: " &lt;&lt; stack5.front() &lt;&lt; endl;
</code></pre>
