Compile-time calculation: Difference between revisions
→{{header|PowerShell}}
No edit summary |
|||
Line 705:
=={{header|PowerShell}}==
<lang PowerShell>
function
$fact = [BigInt]::One
▲ if($n -gt 0) {
$
}
} else {
Write-Error "$n is lower than 0"
}
▲ $res
}
"$((Measure-Command {
$fact
</lang>
<b>Output:</b>
<pre>
0.
3628800
</pre>
|