Skip to main content

11.3) Results


The 2c2 indicates that it is line 2 (left file i.e. ‘file1’) needs to change with line 2 (right file i.e. ‘file4’) in order for the files to agree. When you entered the diff command followed by file1 and file4, the order of file1 and file4 is important. The file1 refers to the file on the left and the file4 is on the right. The following lines show you what is on the line of the left file (i.e. ‘file1’) and indicates what needs to change (indicated by a ‘<’ as if to point to the left, nothing to do with redirection!) relative to the file on the right (‘file4’, indicated by a ‘>’, as if to point to the right file). If you corrected the lines that it indicates then the two files would agree.