title: How to use bash's find arguments in if statements?
body: <p>Just as the title says. I know how to use find's arguments in line with it, but not how to use them as if statements while evaluating a find return variable.  For example:</p>
  
  <pre><code>find . -type f
  </code></pre>
  
  <p>This obviously finds all the files, and how I'm looking to use it is:</p>
  
  <pre><code>ARRAY=$(find .)
  for item in $ARRAY
  do
  if [[ -f $item ]] ; then
  </code></pre>
  
  <p>And that does the same thing, it only deals with the files from the find.  I obviously know how to do it with the <code>-type</code> argument, but not the others.  For example:</p>
  
  <pre><code>find . -size +512k
  </code></pre>
  
  <p>if I want size, doing <code>if [[ -size +512k $item ]]</code> doesn't seem to work as expected.  How do I use it?</p>
  
  <p>Others I can't figure out how to use:</p>
  
  <pre><code>find . -executable
  find . \( -name "*.html" -or -name "*.css" \)
  find . -mtime +364
  </code></pre>
  
  <p>How would I use each of these in <code>if</code> statements if I'm looping over the results of a find?</p>
  
  <p>Additionally, how would I grab the total size of a find result, after the fact, not during the find.   Say I have my <code>ARRAY=$(find .)</code> and what to do a <code>du -ch</code> against my <code>$ARRAY</code> variable.  How would I do that?</p>
  
  <p>Sorry, I'm a bash noob and its syntax is proving difficult for me.</p>