code: public int size()
      {
          Node<E> head = this.head;
          final Node<E> tail = this.tail;
          int size = 0;
  
          while (tail != head && size < Integer.MAX_VALUE)
          {
              final Node<E> next = head.next;
              if (null == next)
              {
                  break;
              }
  
              head = next;
              ++size;
          }
  
          return size;
      }
docs: Size can be considered an approximation on a moving list.
  It is only really stable when the consumer is inactive.
  If you want to check for {@code queue.size() == 0} then {@link #isEmpty()} is a better alternative.
  <p>
  This operation is O(n) on the length of the linked chain.
  
  @return an approximation for the size of the list.