Thanks,I see difflib.Differ().compare() can do this action, I will change it..