Skip to content

Batch Script Unary Operators

Learn about batch script unary operators (~, !, -) and how the tilde (~) shortens long directory names for path simplification.

The batch script language have unary operators.

The following table lists the available unary operators.

Operators Description
~ Tilde operator
! Boolean NOT operator (negation)
- Unary minus operator
Navigation