title: Exclude directories in find that don't contain a specific filename?
body: <p>Let's say I have a directory containing a number of subdirectories, each with a number of files in them. I wish to check which of these directories do not contain a specific file. For example, if these are my directories:</p>
  
  <pre><code>dir/A:
      foo
      bar
  dir/B:
      bar
  dir/C:
      foo
  dir/D:
  dir/E:
      foo
      bar
  </code></pre>
  
  <p>If I wanted to list all directories not containing <code>foo</code>, I would get:</p>
  
  <pre><code>dir/B
  dir/D
  </code></pre>
  
  <p>Is it possible to do this with unix <code>find</code>, or do I need to use some alternate tool? </p>