what is the difference between commmands cmp and diff?
Answer Posted / deepa rajendran
The cmp command compares two files, and (without options)
reports the location of the first
difference between them. It can deal with both binary and
ASCII file comparisons. It does a
byte-by-byte comparison.
But in diff compares two files, directories, etc, and
reports all differences between the two. It
deals only with ASCII files. It’s output format is designed
to report the changes necessary to convert
the first file into the second.
| Is This Answer Correct ? | 15 Yes | 3 No |
Post New Answer View All Answers
Are you in or at the office?
Which command is used to delete all files in the current directory and all its sub-directories?
How do I search for text in vi?
Which command is used to kill the last background job?
What is sed awk grep?
What is the pipe command?
Which unix command lists files/folders in alphabetical order?
What is time_t?
Is ‘du’ a command? If so, what is its use?
What do chown command do?
What are grep patterns?
What is the use of sed command in unix?
What do chmod, chown, chgrp commands do?
What happens when we execute a unix command?
How to display no of records in oracle using unix command?