Export (0) Print
Expand All
Expand Minimize

Converting VBScript's Subtraction Operator


Windows PowerShell


Definition: Finds the difference between two numbers or indicates the negative value of a numeric expression.

Subtraction Operator

Actually, no, we don’t know what 22,018 minus 1,915 is. But Windows PowerShell can determine that difference for us; just use the minus sign (-) as the subtraction operator.


$a = 22018 - 1915

Well, what do you know? We were right: the answer is 20103.


Return to the VBScript to Windows PowerShell home page

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft