system('cmp','-s',$file1,$file2) and print "Files are different!\n"; [download]
In reply to Re: `diff`ing two files (code) by runrig in thread `diff`ing two files (code) by deprecated