@Override
	public int index(E x) {
		Node ptr = this.head; // Start at the beginning of the list
		for (int i = 0; ptr.next != null; i ++, ptr = ptr.next) { // Each iteration until the end of the loop is reached or the body of the for loop causes the method to end:
			if (ptr.data.equals(x)) { // Check if the data of ptr in this iteration is equal to that of x
				return i; // If so, return the current index
			}
		}

		return -1; // If the method got this far x is not in the list, so return -1
	}