title: Find files starting with NULs
body: <p>How do I efficiently find all the files in the system whose contents starts with \x0000000000 (5 NUL bytes)?
  Tried to do the following</p>
  
  <pre><code>$ find . -type f -exec grep -m 1 -ovP "[^\x00]" {} 
  $ find . -type f -exec grep -m 1 -vP "^\00{5}" {} 
  </code></pre>
  
  <p>but the first variant works only for all-NUL files, and the last one searches through the whole file, not only the first 5 bytes, which makes it very slow and gives many false positives.</p>