The dollar sign (`$`) is a special replace pattern, and `$&` inserts the matched string. Thus dollars signs need to be escaped with the special pattern `$$`, which inserts a single `$`.