title: PowerShell: how to get if else construct right?
body: <p>I'm trying to learn powershell and tried to construct a if else statement:</p>
  
  <pre><code>if ((Get-Process | Select-Object name) -eq "svchost") {
      Write-Host "seen"
      }
      else {
      Write-Host "not seen"
      }
  </code></pre>
  
  <p>This ends up into "not seen", although there is svchost processes. How to modify this to get correct results?</p>