title: shell iteration while skipping nodes
body: <p>I have 20 nodes out of which 5 does not ssh(this is expected).
  These values are dynamically pulled from a source.
  Below is my code trying to check if they are able to SSH:</p>
  <pre><code>for skip_node in &quot;${skip_nodes[@]}&quot;
  do 
      for node in &quot;${nodes[@]}&quot;
      do
  
          if [[  $node != $skip_node ]]; then continue; fi
  
          &lt;I have my ssh logic working here&gt;
          if [ $? -ne 0 ]; then
              UNABLE_TO_SSH+=&quot; ${node}&quot;
              (( ERROR_COUNT += 1 ))
          fi
      done
  done
  </code></pre>
  <p>This script is failing because array nodes again contains those nodes which are in skip_nodes.
  Any help on how should can I solve this problem?</p>