1

I have found that,

$ :       Matches the end of the line
\s:       Matches whitespace 
\S:       Matches any non-whitespace character

But what exactly does \$ do ?

MAX
  • 1,316
  • 3
  • 13
  • 22

2 Answers2

5

\$ will help to find the character "$" available in the content based on the expression flags assigned to the regular expression.

Say for example:

\$: only find the single "$" in a content \$/g: find the "$" globally available in content.

Please find the screenshot, which can give you clear idea.

\$: Expression \$ \$ with Global expression: \$ with Global expression

BHUVANESH MOHANKUMAR
  • 2,517
  • 1
  • 30
  • 33
1

\$ just escapes the $ character so it will match $ literally

10100111001
  • 1,712
  • 1
  • 9
  • 7