PS
PLAGIARISM CHECKER
find the matches yourself, then let the algorithm
NTupleChecker.ts
1function buildNTuples<T>(2 items: T[], size: number3): NTuple<T>[] {4 const tuples: NTuple<T>[] = [];5 for (let i = 0; i <= items.length - size; i++)6 tuples.push({ elements: items.slice(i, i + size),7 startIndex: i });8 return tuples;9}1011function findMatchesSync<T>(12 config: MatcherConfig<T>,13 tuplesA: NTuple<T>[],14 tuplesB: NTuple<T>[]15): MatchResult<T>[] {16 const results: MatchResult<T>[] = [];17 for (const ta of tuplesA) {18 for (const tb of tuplesB) {19 if (tuplesMatch(config, ta, tb))20 results.push({ tupleA: ta, tupleB: tb });21 }22 }23 return results;24}
Document Aclick words you think match
thequickbrownfoxjumpsoverthelazydogneartheriverbankthedogwassleepingpeacefullyinthewarmafternoonsunasmallbirdwatchedfromanearbytreebranch
Document B
thequickbrownfoxjumpsoverthelazydogneartheriverbankthedogwasrestingpeacefullyinthewarmafternoonsunatinybirdwatchedfromanearbytreebranch
mode
n-gram
complexityeasy
found 0/27similarity
0%