9. shell script to create 2 data files and compare them to display unique and common entries.

echo "enter the names of existing filenames"
read file1 file2

sort -n $file1 | uniq > ff1
sort -n $file2 | uniq > ff2

echo "comparing two files for displaying unique and common entries"
comm ff1 ff2

No comments

Powered by Blogger.