Comparison operators

Comparison operators are used for comparing two mathematical expressions which results in true, false or unknown.

PowerShell has a wide variety of comparison operators which are as follows:

  • Equal to and not equal to: -eq and -ne
  • Like and not like: -like and -notlike
  • Greater than and greater than or equal to: -gt and -ge
  • Less than and less than or equal to: -lt and -le
  • Contains and not contains: -contains and -notcontains
  • In and not in: -in and -notin
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.222.184.0