Linux time on Windows

In powershell:

notepad C:\Users\$env:USERNAME\Documents\PowerShell\Microsoft.PowerShell_profile.ps1
function time {
    $sw = [Diagnostics.Stopwatch]::StartNew()
    Invoke-Expression ($args -join " ")
    $sw.Stop()
    Write-Host "Time elapsed: $($sw.Elapsed)" -ForegroundColor Cyan
}
 . $PROFILE