다음을 통해 공유


PowerShell Trick to get Random Decimal Number

Question:

How to get Random Decimal Numbers using PowerShell?

Solution:

 
help Get-Random -Detailed 

Code:

 
$output = Get-Random -Maximum 10.49 -Minimum 1.2            
"{0:N2}" -f $output 

Output: