Adding additional files, P Heckel's algo and formatDiff function