USF-OS / FogOS

Other
1 stars 24 forks source link

added comm utility #45

Open kat-le opened 4 months ago

kat-le commented 4 months ago

Added the comm utility which takes two sorted files and prints out lines unique to the first file in the 1st column, lines unique to the second file int the 2nd column, and lines common to both files in the 3rd column. Optional flags: -1 : omits first column from output -2 : omits 2nd column from output -3 : omits third column from output

Usage: /comm [-1 | -2 | -3] file1 file2 Files: comm.c and testcomm.c in user directory, text1.txt and text2.txt are the files used for testing

andrewdiep1 commented 4 months ago

anson and i will code review this one ;0

malensek commented 2 months ago

Nice test suite, clean code. I'm not 100% sure if I understood the CR above so please take a look and make sure that concern is addressed (via reply or bug fix if problem). However, I will note that I ran several new test cases on this and compared with the standard comm and the results all matched -- so I'm satisfied!