private int getMatchCountFromEnd() {

		// scan past the trailing equal items
		int xi = lengthOf(xSource) - 1;
		int yi = lengthOf(ySource) - 1;

		int n = 0;
		for (; xi >= 0 && yi >= 0; xi--, yi--) {
			T xt = valueOf(xSource, xi);
			T yt = valueOf(ySource, yi);
			if (!matches(xt, yt)) {
				return n == 0 ? 0 : n - 1;
			}
			n++;
		}

		return 0;
	}
Return the value at the given 0-based offset
 
@param i the input sequence (x or y)
@param offset the offset
@return the value
Ghidra/Framework/Generic/src/main/java/generic/algorithms/ReducingLcs.java