Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Comparing two text files and marking differences

by BillKSmith (Prior)
on Jan 31, 2021 at 04:05 UTC ( #11127702=note: print w/replies, xml ) Need Help??


in reply to Comparing two text files and marking differences

Although your task sounds simple, it is impossible to implement perfectly. Given any example, you know exactly what you want. Specifying how to handle that case is not too hard, but real-world examples do not always fall neatly into classes. You have not even considered the problem of text being rearranged. What if it is rearranged and then edited? At what point do you consider a sentence a replacement rather than an edit?

I recommend that you 'audition' several of the modules that have been suggested. Choose the one that seems the best. Accept the fact that you will not always like its output.

Bill
  • Comment on Re: Comparing two text files and marking differences

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11127702]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (2)
As of 2021-04-16 02:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?