Created
December 20, 2017 22:35
-
-
Save rglos/987d5e8ba0fa561cab53c3a5e6c30603 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To return a result string in which absent digits or leading zeroes are replaced by spaces, use | |
# the composite formatting feature and specify a field width | |
# https://docs.microsoft.com/en-us/dotnet/standard/base-types/composite-formatting | |
# specify 3 spaces | |
Write-Host ("{0,3:N0} 2345" -f 1) | |
# Output: | |
# 1 2345 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment