Text & Analysispublic tool
Text Diff
Compare two texts line by line with a real LCS diff — see exactly what was added, removed, and left untouched.
- Added
- 4
- Removed
- 4
- Unchanged
- 3
- Similarity
- 43%
Differences
4 added · 4 removed · 3 unchanged
44
| A | B | Line |
|---|---|---|
| 1 | −function greet(name) { | |
| 2 | − console.log("hello") | |
| 3 | − return name | |
| 1 | +function greet(name, punctuation = "!") { | |
| 2 | + console.log(`hello`) | |
| 3 | + return name + punctuation | |
| 4 | 4 | } |
| 5 | 5 | (empty line) |
| 6 | 6 | const result = greet("world") |
| 7 | −console.log(result) | |
| 7 | +console.log(result.toUpperCase()) |
Original
7 lines
Updated
7 lines