public boolean containsAll(Collection< ? > c) { if (c.isEmpty()) return true; if (isEmpty()) return false; // TODO take advantage of sorted nature for this for (Object el : c) { if (!contains(el)) return false; } return false; }
@Override public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
@Override public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(end - 1); }
public boolean containsAll(Collection< ? > c) { if (c.isEmpty()) return true; if (isEmpty()) return false; // TODO take advantage of sorted nature for this for (Object el : c) { if (!contains(el)) return false; } return false; }
@Override public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
public boolean containsAll(Collection< ? > c) { if (c.isEmpty()) return true; if (isEmpty()) return false; // TODO take advantage of sorted nature for this for (Object el : c) { if (!contains(el)) return false; } return false; }
@Override public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
public T first() { if (isEmpty()) throw new NoSuchElementException("first"); return get(0); }
@Override public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(size() - 1); }
@Override public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(size() - 1); }
public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(size()-1); }
public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(size()-1); }
public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(size()-1); }
public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(size()-1); }
@Override public T last() { if (isEmpty()) throw new NoSuchElementException("last"); return get(size() - 1); }