if [ -s bwt.txt ]; then rm bwt.txt fi if [ -s bwt-back.txt ]; then rm bwt-back.txt fi javac BWT.java java BWT $1 % bwt.txt java BWT bwt.txt % bwt-back.txt cpmResult=$(cmp $1 bwt-back.txt) if [ "${cpmResult}" == "" ]; then echo "The BWT output is equal to the original file." else echo "The output is not equal." cmp $1 bwt-back.txt fi