Here is my code:
# hi.ps1
function fun
{
Write-Host $args
}
Write-Host '---------------'
Write-Host $args
Write-Host '---------------'
fun
Write-Host '---------------'
This is the output:
PS C:\scratch> .\hi there jim
---------------
there jim
---------------
---------------
My question is, why isn't $args visible within fun?