PowerShell Return behavior in PowerShell Return with a value


Example

(paraphrased from about_return)

The following methods will have the same values on the pipeline

function foo {
    $a = "Hello"
    return $a
}

function bar {
    $a = "Hello"
    $a
    return
} 

function quux {
    $a = "Hello"
    $a
}