Toolkit for Judging Question
npm install judging-question-toolkit
# yarn
yarn add judging-question-toolkit
# pnpm
pnpm install judging-question-toolkit
- Diff the same part of strings between
Answer
andInput
import { DiffAnsSame } from "judging-question-toolkit"
const res = DiffAnsSame("abcdfg", "cdefh")
console.log(res)
/**
* Output:
* [ [ 2, 3, 4 ], [ 0, 1, 3 ] ]
*/
For more, see the source code
The git commit messages are generated by developer-helper-cli (DHC)
Open source under MIT