public void insertAt(int index, int val) throws InvalidAccessException {
		if (index - 1 < 0) {
			throw new InvalidAccessException("Index < 0");
		}
		if (this.head == null) {
			DLNode n = new DLNode();
			this.head = n;
			this.tail = n;

		}

		if (this.countElements() - 1 > index - 1) {
			if (isNodeInitialized(index - 1) == true) {
				DLNode newNode = new DLNode(val);
				DLNode current = runToIndex(index - 2);

				DLNode next = current.getNext();

				newNode.setPrev(current);
				newNode.setNext(next);
				current.setNext(newNode);
				next.setPrev(newNode);

			} else {
				DLNode current = runToIndex(index - 1);

				current.setVal(val);
			}
		} else { // countElement< index
			DLNode current = this.tail;

			for (int i = this.countElements() - 1; i < index - 1; i++) {
				DLNode newNode = new DLNode();
				newNode.setPrev(current);
				current.setNext(newNode);

				current = current.getNext();
			}
			current.setVal(val);
			tail = current;

		}

	}