internal object Pop() { if (Count == 0) throw new InvalidOperationException("The stack is empty."); object obj = this[Count - 1]; RemoveAt(Count - 1); return obj; } }