home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / lang / perl / 5946 < prev    next >
Encoding:
Text File  |  1992-09-15  |  1.1 KB  |  33 lines

  1. Newsgroups: comp.lang.perl
  2. From: Sean@legastat.demon.co.uk (Sean Hughes)
  3. Path: sparky!uunet!pipex!demon!legastat.demo.co.uk!Sean
  4. Subject: DIFF
  5. Distribution: world
  6. Organization: Legastat
  7. Lines: 20
  8. Date: Tue, 15 Sep 1992 16:38:51 +0000
  9. Message-ID: <716575131snx@legastat.demo.co.uk>
  10. Sender: usenet@gate.demon.co.uk
  11.  
  12. Hello happy perl people
  13.  
  14. Has anyone written a diff-like routine?
  15.  
  16. What I'm trying to do is to compare a target line of text against a
  17. whole document in order to find the text that matches the target most
  18. closely at a charcater level.  The hamfisted approach would be to use
  19. split to break each line into one character per line lines and run 
  20. system calls to diff - but this strikes me as pretty silly.
  21.  
  22. I appreciate I should get into the diff algorithms(^) but before I start
  23. re-inventing square wheels has anybody done this kind of thing already ?
  24.  
  25. (^ does anyone know an ftp or some such site where I can get hold of:
  26. "An O(ND) Difference Algorithm and its Variations", Eugene Myers,
  27. Algorithimica Vol. 1 No. 2, 1986, p251 )
  28.  
  29. Many thanks
  30.  
  31. Sean at the core dump
  32.  
  33.