difference(OtherLinkedListPointersForStep, diff) {
        if (this.size() !== OtherLinkedListPointersForStep.size()) {
            if (this.size() < OtherLinkedListPointersForStep.size())
                diff.pointerForStep.size = JSON.stringify({ addPointers: this.size(), To: OtherLinkedListPointersForStep.size() });
            else
                diff.pointerForStep.size = JSON.stringify({ removePointers: this.size(), To: OtherLinkedListPointersForStep.size() });
        } else { //same size put change in pointers locations
            for (var i = 0; i < this.size(); i++) {
                if (!this.getPointer(i).equals(OtherLinkedListPointersForStep.getPointer(i))) {
                    diff.pointerForStep.pointer = {};
                    diff = this.getPointer(i).difference(OtherLinkedListPointersForStep.getPointer(i), diff, i);
                }
            }
        }
        return diff;
    }
/**
     * Calculats the difference between this linked list pointers and the other linkedlist pointers
     * @param {LinkedListPointersForStep} OtherLinkedListPointersForStep The other linked list pointers that will be compared with this linked list pointers
     * @param {Hash} diff Hash table
     */
Calculats the difference between this linked list pointers and the other linkedlist pointers
@param {LinkedListPointersForStep} OtherLinkedListPointersForStep The other linked list pointers that will be compared with this linked list pointers
@param {Hash} diff Hash table
Calculats the difference between this linked list pointers and the other linkedlist pointers @param { LinkedListPointersForStep } OtherLinkedListPointersForStep The other linked list pointers that will be compared with this linked list pointers @param { Hash } diff Hash table
difference(OtherLinkedListPointersForStep, diff) {
        if (this.size() !== OtherLinkedListPointersForStep.size()) {
            if (this.size() < OtherLinkedListPointersForStep.size())
                diff.pointerForStep.size = JSON.stringify({ addPointers: this.size(), To: OtherLinkedListPointersForStep.size() });
            else
                diff.pointerForStep.size = JSON.stringify({ removePointers: this.size(), To: OtherLinkedListPointersForStep.size() });
        } else { 
            for (var i = 0; i < this.size(); i++) {
                if (!this.getPointer(i).equals(OtherLinkedListPointersForStep.getPointer(i))) {
                    diff.pointerForStep.pointer = {};
                    diff = this.getPointer(i).difference(OtherLinkedListPointersForStep.getPointer(i), diff, i);
                }
            }
        }
        return diff;
    }
difference ( OtherLinkedListPointersForStep , diff ) { if ( this . size ( ) !== OtherLinkedListPointersForStep . size ( ) ) { if ( this . size ( ) < OtherLinkedListPointersForStep . size ( ) ) diff . pointerForStep . size = JSON . stringify ( { addPointers : this . size ( ) , To : OtherLinkedListPointersForStep . size ( ) } ) ; else diff . pointerForStep . size = JSON . stringify ( { removePointers : this . size ( ) , To : OtherLinkedListPointersForStep . size ( ) } ) ; } else { for ( var i = 0 ; i < this . size ( ) ; i ++ ) { if ( ! this . getPointer ( i ) . equals ( OtherLinkedListPointersForStep . getPointer ( i ) ) ) { diff . pointerForStep . pointer = { } ; diff = this . getPointer ( i ) . difference ( OtherLinkedListPointersForStep . getPointer ( i ) , diff , i ) ; } } } return diff ; }
Calculats the difference between this linked list pointers and the other linkedlist pointers
 @param {LinkedListPointersForStep} OtherLinkedListPointersForStep The other linked list pointers that will be compared with this linked list pointers
 @param {Hash} diff Hash table
Calculats the difference between this linked list pointers and the other linkedlist pointers @param { LinkedListPointersForStep } OtherLinkedListPointersForStep The other linked list pointers that will be compared with this linked list pointers @param { Hash } diff Hash table
//same size put change in pointers locations