 <p>Use <code>head -c</code> to specify the number of bytes for each file and then compare them.</p> <p>I believe this requires creating at least one temporary file, but would appreciate any comments otherwise :)</p>