in reply to How compare two files

Have you looked at Algorithm::Diff?

Update: Gah. Misread the question.