Pipelines and loops in PowerShell