title: What does "%" (percent) do in PowerShell?
body: <p>It seems that the % operation starts script blocks after the pipeline, although <a href="http://technet.microsoft.com/en-us/library/hh847893.aspx" rel="noreferrer">about_Script_Blocks</a> indicates the % isn't necessary.</p>
  
  <p>These all work just fine.</p>
  
  <pre><code>get-childitem | % { write-host $_.Name }
  
  { write-host 'hello' }
  
  % { write-host 'hello' }
  </code></pre>
  
  <p>But when we add a script block after the pipeline, we need to have the % first.</p>
  
  <pre><code>get-childitem | { write-host $_.Name }
  </code></pre>