title: Difference between Stack.capacity() and Stack.size()
body: <p>I am currently doing a check with the <code>Stack&lt;E&gt;</code> class to see if it's full. However, List does not have a <code>isFull()</code> implementation, so I am asking to check if <code>capacity()</code> is the same as <code>size()</code>. According to the docs, <code>size()</code> returns the number of components in this vector, and capacity returns the current capacity of the vector. If I understand correctly, are they the same? And if so, how do I go about checking if my <code>Stack&lt;E&gt;</code> is full?</p>