removeLast method

  1. @override
E removeLast()
override

Removes the last element from this queue.

Throws NoGuaranteeException if this queue is empty.

Implementation

@override
E removeLast() {
  if (_elements.isEmpty) {
    throw NoGuaranteeException('Queue is empty');
  }
  return _elements.removeLast();
}